mirror of
https://github.com/huggingface/lerobot.git
synced 2026-05-23 20:50:02 +00:00
fix(profiling): publish preview rows to existing dataset
This commit is contained in:
@@ -81,7 +81,7 @@ jobs:
|
||||
HF_USER_TOKEN: ${{ secrets.LEROBOT_HF_USER }}
|
||||
PROFILE_MODE: ${{ github.event_name == 'pull_request' && 'summary' || github.event.inputs.profile_mode || 'trace' }}
|
||||
POLICY_FILTER: ${{ github.event_name == 'pull_request' && 'act' || github.event.inputs.policies || '' }}
|
||||
RESULTS_REPO: ${{ github.event_name == 'pull_request' && 'model-profiling-history-preview' || github.event.inputs.results_repo || 'model-profiling-history' }}
|
||||
RESULTS_REPO: ${{ github.event.inputs.results_repo || 'model-profiling-history' }}
|
||||
SHOULD_PUBLISH: ${{ github.event_name == 'pull_request' || github.event_name == 'schedule' || (github.event_name == 'workflow_dispatch' && github.event.inputs.publish_results == 'true') }}
|
||||
steps:
|
||||
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
|
||||
|
||||
@@ -61,7 +61,12 @@ def upload_targets(
|
||||
commit_message: str | None = None,
|
||||
) -> dict[str, str]:
|
||||
api = HfApi(token=token)
|
||||
api.create_repo(repo_id=repo_id, repo_type=repo_type, private=private, exist_ok=True)
|
||||
try:
|
||||
repo_exists = api.repo_exists(repo_id=repo_id, repo_type=repo_type)
|
||||
except Exception:
|
||||
repo_exists = True
|
||||
if not repo_exists:
|
||||
api.create_repo(repo_id=repo_id, repo_type=repo_type, private=private, exist_ok=True)
|
||||
uploaded: dict[str, str] = {}
|
||||
for target in targets:
|
||||
api.upload_file(
|
||||
|
||||
Reference in New Issue
Block a user