Skip to content

Add this as an exampla for datalad data exchange #114

@marcobarilari

Description

@marcobarilari

title: DATALAD made simple for data exchange


DATALAD made simple for data exchange

Set up of the repo online and localy

  1. Create the repo on GIN / CPP-lab organization 2026_SaintLuc_ProjectName_EG_source

  2. Add Salomé and Eleonore as admin

  3. Clone the repo on each computer

datalad install xxx
  1. Basic organization of the repo as sourcedata
2026_SaintLuc_ProjectName_EG_source
.
├── README.md
├── code
├── sub-EB01
│   ├── ses-01
│   │   ├── func
│   │   └── dicom
│   └── ses-02
│       ├── func
│       └── dicom
└── sub-EB02
    ├── ses-01
    │   ├── func
    │   ├── dicom
    ├── ses-02
    │   ├── func
    │   └── dicom
    └── ses-03
        ├── func
        └── dicom
[...]

Day by day data exchange

Salomê uploads and Eleonore get the data

Salomé:

  1. Check the status of the repo
cd path/to/2026_SaintLuc_ProjectName_EG_source

datalad status

if datalad says it is all ok then you can add new data, otherwise check with Marco

  1. copy the data (or drag and drop) in the respective folder (sub-xx/ses-xx/dicom or func), do it subject by subject and session by session

  2. check that the repo sees the new data (untracked)

datalad status
  1. save the new data so that datalad will keep track of them
datalad save -m "add dicoms and logfiles for sub-xx for ses-xx"
  1. if everything goes well (if not ask Marco), then push the data to gin, do not close the computer until the upload is done. When it is done tell Eleonore it is done.
datalas push --to origin -J 4
  1. if you do not need those data anymore on your computer, then drop them (the file exist as a ghost file on your computer and you can download it again from GIN when you need it)
datalad drop sub-xx/ses-xx

Eleonore

  1. Go to the data folder, before downloading new data check everything is allright
cd path/to/2026_SaintLuc_ProjectName_EG_source

datalad status

To deeper in the quest of checking that everything is allright and the local and origin repo are at the same level

git log --all --oneline
  1. if everythogn is allright (there no files which are changed or untracked), update the repo
datalad update --merge
  1. Dowload the data
datalad get sub-xx/ses-xx -J
  1. Move the data out of datalad to ...
mkdir -p folder/no/datalad/sub-xx/ses-xx

cp -L sub-xx/ses-xx folder/no/datalad/sub-xx/ses-xx
  1. Remove the local data from the datalad repo
datalad drop sub-xx/ses-xx

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions