pyworkflow.apps.pw_sync_data module

Scipion data synchronization.

Get(put) tests data, from(to) the server to(from) the $SCIPION_TESTS folder.

pyworkflow.apps.pw_sync_data.ask(question='Continue? (y/n): ', allowed=None)[source]

Ask the question until it returns one of the allowed responses

pyworkflow.apps.pw_sync_data.check(dataset, url, verbose=False, updateMANIFEST=False)[source]

See if our local copy of dataset is the same as the remote one. Return True if it is (if all the checksums are equal), False if not.

pyworkflow.apps.pw_sync_data.createMANIFEST(path)[source]

Create a MANIFEST file in path with the md5 of all files below

pyworkflow.apps.pw_sync_data.download(dataset, destination=None, url=None, verbose=False)[source]

Download all the data files mentioned in url/dataset/MANIFEST

pyworkflow.apps.pw_sync_data.get_parser()[source]

Return the argparse parser, so we can get the arguments

pyworkflow.apps.pw_sync_data.listDatasets(url)[source]

Print a list of local and remote datasets

pyworkflow.apps.pw_sync_data.main()[source]
pyworkflow.apps.pw_sync_data.md5sum(fname)[source]

Return the md5 hash of file fname

pyworkflow.apps.pw_sync_data.update(dataset, workingCopy=None, url=None, verbose=False)[source]

Update local dataset with the contents of the remote one. It compares the md5 of remote files in url/dataset/MANIFEST with the ones in workingCopy/dataset/MANIFEST, and downloads only when necessary.

pyworkflow.apps.pw_sync_data.upload(dataset, login, remoteFolder, delete=False)[source]

Upload a dataset to our repository