sfaira.ui.UserInterface.deposit_zenodo

UserInterface.deposit_zenodo(zenodo_access_token: str, title: str, authors: list, description: str, metadata: dict = {}, update_existing_deposition: Optional[str] = None, publish: bool = False, sandbox: bool = False, deposit_topologies: bool = True)

Deposit all models in model lookup table on Zenodo. If publish is set to false, files will be uploaded to a deposition draft, which can be further edited (additional metadata, files etc.). Returns the DOI link if publish=True or a link to the deposition draft if publish=False.

Parameters
  • zenodo_access_token – Your personal Zenodo API access token. Create one here: https://zenodo.org/account/settings/applications/tokens/new/

  • title – Title of the Zenodo deposition

  • authors – List of dicts, where each dict defines one author (dict keys: name: Name of creator in the format “Family name, Given names”, affiliation: Affiliation of creator (optional), orcid: ORCID identifier of creator (optional), gnd: GND identifier of creator (optional)

  • description – Description of the Zenodo deposition.

  • metadata – Dictionary with further metadata attributes of the deposit. See the Zenodo API refenrece for accepted keys: https://developers.zenodo.org/#representation

  • update_existing_deposition – If None, a new deposition will be created.

If an existing deposition ID is provided as a sting, than this deposition will be updated with a new version. :param publish: Set this to True to directly publish the weights on Zenodo.

When set to False a draft will be created, which can be edited in the browser before publishing.

Parameters

sandbox – If True, use the Zenodo testing platform at https://sandbox.zenodo.org for your deposition. We recommend testing your upload with sandbox first as depositions cannot be deleted from the main Zenodo platform once created. :param deposit_topologies: If true, an associated topology file for every weights file will be uploaded to zenodo. The naming format for the topology files is <model_id>_topology.pickle