QIICR / dcmqi-faq

Frequently Asked Questions for http://github.com/qiicr/dcmqi
0 stars 0 forks source link

How to use pixelmed tools for dcmqi-produced objects? #5

Open fedorov opened 8 years ago

fedorov commented 8 years ago

Download the toolkit here here: http://www.dclunie.com/pixelmed/software/

Here are some things you can do with Pixelmed toolkit. Run the commands from the directory with the binary installation.

Overlay SEG using Pixelmed tools

First, convert image data into multiframe:

java -Xmx512m -Xms512m -cp "./pixelmed.jar:./lib/additional/hsqldb.jar:./lib/additional/excalibur-bzip2-1.0.jar:./lib/additional/vecmath1.2-1.14.jar:./lib/additional/jmdns.jar:./lib/additional/commons-codec-1.3.jar:./lib/additional/jai_imageio.jar" 
  com.pixelmed.dicom.MultiFrameImageFactory <input_folder> <output_folder>

Next, you can overlay the segmentation over that multiframe image:

java -Xmx512m -Xms512m -cp "./pixelmed.jar:./lib/additional/hsqldb.jar:./lib/additional/excalibur-bzip2-1.0.jar:./lib/additional/vecmath1.2-1.14.jar:./lib/additional/jmdns.jar:./lib/additional/commons-codec-1.3.jar:./lib/additional/jai_imageio.jar" 
  com.pixelmed.display.SuperimposedDicomImage <multiframe_image> <segmentation>

Validate SR object

bash DicomSRValidator.sh <sr_object>
sedghi commented 3 years ago

Hi Andrey, I'm trying to use Pixelmed tool to convert multiple dicom files into a multiframe dicom. The link mentioned above does not work anymore, I could find the .jar file here (http://www.dclunie.com/pixelmed/software/20200716_current/index.html) Then from the folder that contains the .jar file, I'm opening a terminal, and type

java -Xmx512m -Xms512m -cp "./pixelmed.jar:./lib/additional/hsqldb.jar:./lib/additional/excalibur-bzip2-1.0.jar:./lib/additional/vecmath1.2-1.14.jar:./lib/additional/jmdns.jar:./lib/additional/commons-codec-1.3.jar:./lib/additional/jai_imageio.jar"
  com.pixelmed.dicom.MultiFrameImageFactory /Users/alireza/dicom/PROSTATEx/ProstateX-0004/1.3.6.1.4.1.14519.5.2.1.7311.5101.271991298059338527584681788043/ /Users/alireza/dicom/PROSTATEx/ProstateX-0004/output/

image

However, it doesn't run the program and give me zsh: command not found: com.pixelmed.dicom.MultiFrameImageFactory I also tried running it with

java -jar ./pixelmed.jar

but got no main manifest attribute, in ./pixelmed.jar

I also tried downloading the pixelmedjavadicom_binaryrelease.20200716.tar.bz2 and running the same commands there too, but no luck.

I haven't had previous experience with running java files, maybe i'm missing something very obvious?

fedorov commented 3 years ago

It must be something about your system - this works for me with the same binary release:

image

sedghi commented 3 years ago

You are right, I had an unwanted character in my commands, now it is working. thanks for your help @fedorov I had to download pixelmedjavadicom_dependencyrelease.20200716.tar.bz2 also and put it in the ./lib of the binaries, as it is required (and referenced in the cp).