cubids.metadata_merge.merge_json_into_json

merge_json_into_json(from_file, to_file, raise_on_error=False)[source]

Merge imaging metadata into JSON.

Parameters:
  • from_file (str) – Path to the JSON file to merge from.

  • to_file (str) – Path to the JSON file to merge into.

  • raise_on_error (bool, optional) – Whether to raise an exception if there are errors. Defaults to False.

Returns:

Exit code. Either 255 if there was an error or 0 if there was not.

Return type:

int