Skip to content

Upload Ancillary Data via CLI#266

Merged
yuenmichelle1 merged 7 commits into
masterfrom
upload-ancillary-data
Nov 3, 2025
Merged

Upload Ancillary Data via CLI#266
yuenmichelle1 merged 7 commits into
masterfrom
upload-ancillary-data

Conversation

@yuenmichelle1
Copy link
Copy Markdown
Contributor

Allow to upload multiple attached media via CLI given existing subjects. Media creation and upload logic works similar to CLI's panoptes subject-set <SUBJECT_SET_ID> upload-subjects manifest.csv, however, in this case, we do this without a context of subject-set AND this uploads attached media associated to already existing subjects (i.e. we REQUIRE users must input subject ids onto the csv)

Eg command use :

panoptes subject upload-subjects-attached-media manifest.csv

Similar to uploading subjects to a subject set via CLI, we allow externally hosted media. You can put the URLs in manifest and specify the column number(s)
Eg.

panoptes subject upload-subjects-attached-media -r 2 manifest.csv

Eg format of a row of a manifest csv

subject_id | file_name_1 | file_name_2 | metadata

Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Comment thread panoptes_cli/commands/subject.py
Copy link
Copy Markdown
Member

@lcjohnso lcjohnso left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking pretty good (pending any major changes in zooniverse/panoptes-python-client#331), but I raised a question regarding attached image metadata that should be resolved.

Comment thread panoptes_cli/commands/subject.py Outdated
Comment thread panoptes_cli/commands/subject.py Outdated
Comment thread panoptes_cli/commands/subject.py Outdated
yuenmichelle1 and others added 3 commits November 1, 2025 17:54
Co-authored-by: Cliff Johnson <cliff@zooniverse.org>
Co-authored-by: Cliff Johnson <cliff@zooniverse.org>
Comment thread panoptes_cli/commands/subject.py
@yuenmichelle1 yuenmichelle1 merged commit 4ad633a into master Nov 3, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants