Skip to content

Instantly share code, notes, and snippets.

View sscotti's full-sized avatar
💭
Relocating to Sicily, Italy. Limited availability

Stephen Douglas Scotti sscotti

💭
Relocating to Sicily, Italy. Limited availability
View GitHub Profile
@jphdotam
jphdotam / migrate_orthanc.py
Last active November 1, 2024 15:32
Migrate one Orthanc server to another using multiple threads
# this is inspired by the official ImportDicomFiles.py - however, this is MUCH faster because
# it uses multiple workers to dramatically reduce IO bottlenecks
# it doesn't re-instantiate the Http() and headers for every file, rather every folder
# it does assume the input folders are structured in the orthanc format, e.g. /00/00/0000a8768bd86...
# and expects PATH_TO_SYNC to be something like:
## "/path/to/orthanc/root/*" for all root folders
## "/path/to/orthanc/root/1*" for all folders beginning with 1
## "/path/to/orthanc/root/23" for root folder 23 only