Announcement

Collapse
No announcement yet.

Multiple DICOM messages at once to MOSAIQ

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Multiple DICOM messages at once to MOSAIQ

    Hi all,

    Environment information:
    Mirthconnect 2.1.1.5490 (I upgraded to the latest available as part of troubleshooting)
    Host is Windows Server 2003
    Java version is 1.7.0-b147 32 and 64 (also updated as part of troubleshooting)

    The channel I am trying so ineptly to write is attached at the bottom of the message (if I did it right).

    What I am trying to acheive:
    I need DICOM message(s) sent into a channel, modify the MRN (tag 10,20), and send on to a different DICOM AE. This could be a single message or lots of messages (for eg, a Cone Beam CT, 130+ slices)

    What I've done so far:
    I have the Javascript (helped by this very forum) in the source Transformer to do the MRN change.
    ==//==
    msg['tag00100020'].setChildren("C" + msg['tag00100020'].toString());
    ==//==
    The code happily adds the prefix C to the existing MRN and on goes the images. Works brilliantly.

    What I need help with:
    The DICOM sender destination works fine if I send a single message. It grabs the message, changes the MRN, and forwards it on to the target AE. However, if I send a multi-message set, it sends it one message at a time! As in, it closes the association and re-opens after every message.
    ** How can I get it so that the association stays open for as many messages are in the channel? **

    In case it is useful, I am using to send dcm4che's dcmsnd, and to receive both dcmrcv and MOSAIQ (Elekta/Impac radiation oncology software) Dcmwin.exe. MOSAIQ is the desired end result.

    Thanks,
    Telem
    Attached Files

  • #2
    Sample output that I would LIKE to achieve

    I forgot to mention and attach a sample output (from DCMSND when it talks directly to the MOSAIQ Dcmwin.exe) of what I would like Mirthconnect to do.

    So the multimsg_oneassoc.txt file is output from that, in case that helps.

    What Mirth ACTUALLY does is in the multimsg_multiassoc.txt (copied from DCMRCV when used as target).

    Thanks,
    Telem
    Attached Files

    Comment


    • #3
      Did you ever find a solution to this?

      Tim

      Comment


      • #4
        Originally posted by TimOConnor View Post
        Did you ever find a solution to this?

        Tim
        Hi Tim,

        No, sorry, no solution yet. A possible workaround I am testing is to have Mirthconnect dump all the altered DICOM messages in a staging folder per patient-and-study-id, send through a notification message containing that folder to a homebrand process that will then use dcmsnd to do the final DICOM push. Mirthconnect's receiving of DICOM seems fine, and the file writer doesn't suffer quite the same performance problems as the DICOM sender. The timing is tricky though to get right with the big studies, so I'm still working on it.

        I ended up logging this job: http://www.mirthcorp.com/community/i...wse/MIRTH-1930

        A possible related issue (http://www.mirthcorp.com/community/i...wse/MIRTH-1573) at the moment has a projected fix version of 3.0.

        Thanks,
        Telem

        Comment


        • #5
          Proof of concept: Ugly Hack Workaround

          If anyone's interested, this is a methodology that partially "works" on my own private machine, though I am not comfortable implementing it at work. The remaining issue is timing .. I am still tweaking everything to get it to send the TCP message at the right time, but if you want to at least see the thought process, here it is. Obviously the listener should be written in something better than vbScript, and I'll get to that if and when I'm comfortable with the timing from Mirthconnect.

          Disclaimers:
          1. It's not really any more stable than Mirthconnect normally when processing massive DICOM sets.
          2. Do NOT implement this in production, or even seriously develop anything commercial based on it without registering your Ostrosoft product. Any of my ideas are at your own risk, etc etc.
          3. My script has ALL my remaining debug messages enabled. Be warned, clicking will go on.
          4. Thanks to kryologic for pointing me in the right direction here, and even posting (albeit in 2007) a working bit of code for me to adapt.

          Attached is my channel: Dump and notify - DICOM URN change.xml

          It prefixes the C onto incoming DICOM file URN tag, and writes them to a directory structure based on the (new) URN (10,20), and then the Series ID (20,0E).

          If that succeeds, it pushes a TCP message containing in clear text (security awooga) the location of these files to a particular port.

          Also attached is a horrible .vbs script with a .txt extension to get it uploadable, which relies on the Ostrosoft Winsock .dll (free for non-commercial use). It sets up a basic listener, listens for the path coming from Mirthconnect and then sets dcmsnd (from dcm4che) to that directory to get them all to the ACTUAL destination (eg MOSAIQ) in one go. This DOES let MOSAIQ associate them all correctly.

          Let the ridicule commence!

          Telem
          Attached Files

          Comment

          Working...
          X