Script for depositing the data into EMPIAR using EMPIAR API
Project description
Command line tool for depositing data into Electron Microscopy Public Image Archive.
How to use
Please follow these steps:
Create a JSON file according to the structure provided in the example.
Download and install ascp tool.
Set the environmental variable for Aspera password to the one that EMPIAR team has provided you with. Please note that this is not the API token from 1) and is a separate password from the one that you create when registering EMPIAR user.
On Linux and Mac OS X execute
export ASPERA_SCP_PASS=<empiar_aspera_password>
On Windows execute
set ASPERA_SCP_PASS=<empiar_aspera_password>
Run the script as:
empiar-depositor [-h] [-e ENTRY_THUMBNAIL] [-r RESUME RESUME] [-i] [-v] EMPIAR_TOKEN JSON_INPUT ASCP_PATH DATA_PATH
Positional arguments:
EMPIAR_TOKEN
EMPIAR API token. Contact EMPIAR team to obtain it.
JSON_INPUT
The location of the JSON with EMPIAR deposition information.
ASCP
The location of the ascp executable. By default it is installed in ~/.aspera/connect/bin directory on Linux machines, in ~/Applications/AsperaConnect.app/Contents/Resources directory on Macs and in C:Users<username>AppDataLocalProgramsAsperaAspera Connectbin on Windows.
DATA
The location of the data that you would like to upload to EMPIAR. It should contain directories that correspond to the image set directories specified in the JSON file.
Optional arguments:
-h, --help
Show help message and exit
-e ENTRY_THUMBNAIL, --entry-thumbnail ENTRY_THUMBNAIL
Thumbnail image that will represent your deposition on EMPIAR pages. Minimum size is 400 x 400, preferred format is png. If none is provided, then the image from the related EMDB entry will be used.
-r ENTRY_ID ENTRY_DIR, --resume ENTRY_ID ENTRY_DIR
Resume Aspera upload or re-deposit an entry. The entry has to be successfully created as specifying EMPIAR entry ID and entry directory is required. All entry metadata will be replaced with the one provided in the JSON file. Aspera transfer will continue from where it stopped.
-i, --ignore-certificate
Activate this flag to skip the verification of SSL certificate.
-v, --version
Show program’s version number and exit
Examples:
empiar-depositor 0123456789 ~/Documents/empiar_deposition_1.json ~/Applications/Aspera\ Connect.app/Contents/\ Resources/ascp ~/Downloads/micrographs
empiar-depositor -r 10 ABC123 -e ~/Downloads/dep_thumb.png 0123456789 ~/Documents/empiar_deposition_1.json ~/\ Applications/Aspera\ Connect.app/Contents/Resources/ascp ~/Downloads/micrographs
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file empiar-depositor-1.6b3.tar.gz
.
File metadata
- Download URL: empiar-depositor-1.6b3.tar.gz
- Upload date:
- Size: 8.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a9629c59806fd16d0b06c119212479908fef0f3c95723111e87fda6557fad8fe |
|
MD5 | 0cc8eec0eccde46d6fec0c4b534dbb1b |
|
BLAKE2b-256 | e143ee30ae6040df5d973f224aa86621cbd786c0a4f5aa062b21bf81b0c483e2 |