Title: Update MoCo Acquisition Label

Date: 04-03-2020

Description:
This notebook is used to rename MoCo Series based on the Scan Name, end with _moco prefix

Functions:

  1. get_scan_moco_label : Identify the original scan label
  2. modify_acq_name : Modify Acquisition name based on the session timepoint
  3. update_acq_label : Update the acquisition label on the FW instances

Install and import dependencies

Flywheel API Key and Client

Get a API_KEY. More on this at in the Flywheel SDK doc here.

Instantiate the Flywheel API client

Show Flywheel logging information

Constants

Requirements

Before starting off, we want to check your permission on the Flywheel Instance in order to proceed in this notebook.

Tip: Group ID and Project Label can be found on top of the Project page on the Flywheel Instance as shown in the snippet below.

check_user_permission will return True if both the group and project meet the minimum requirement, else a compatible list will be printed.

Helper functions

Main script

Here we will be iterating through each sessions and respective acquisitions, within the project container, to get the series_number, acq_label and the acq_id. Then we will call the update_moco_acq_label function to update the acquisition label.

Display Updated Acquisition Label