Retrieve Series

45 views
Skip to first unread message

Marc Kohli

unread,
Jan 31, 2013, 8:51:33 PM1/31/13
to ruby-...@googlegroups.com
Is it possible with ruby-dicom to retrive a series from an archive given the study UID and the series UID? 

I've been able to get the dcm4che toolkit binary to do something similar, but can't figure out how to do it with ruby-dicom.

Thanks in advance.

Marc Kohli

Christoffer Lervåg

unread,
Feb 1, 2013, 2:39:39 AM2/1/13
to ruby-...@googlegroups.com
Marc,

You should be able to instruct the archive to move the series to a destination of your choice. Try something like this:

destination = 'MY_LOCAL_DICOM_STORAGE_WHICH_THE_ARCHIVE_IS_AWARE_OF'
series = node.find_series('0020,000E' => series_uid)
  series.each do |s|
    images = node.find_images('0020,000D' => s['0020,000D'], '0020,000E' => s['0020,000E'])
    images.each do |image|
      node.move_image(destination, '0008,0018' => image['0008,0018'], '0020,000D' => image['0020,000D'], '0020,000E' => image['0020,000E'])
    end
  end
end




Marc Kohli

--
You received this message because you are subscribed to the Google Groups "ruby-dicom" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ruby-dicom+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Marc Kohli

unread,
Feb 2, 2013, 10:35:55 PM2/2/13
to ruby-...@googlegroups.com
*facepalm*

of course, thanks!!

--Marc
Reply all
Reply to author
Forward
0 new messages