Hi Yari,

great. In that case I will point Matthias to your test file so he can take a 
look at it.
https://www.dropbox.com/s/sl4x4jlch3pp5gp/test_dicom_anon.dcm?dl=0

Best,
Caspar

-----Ursprüngliche Nachricht-----
Von: yari mattei [mailto:yari.mat...@student.supsi.ch] 
Gesendet: Dienstag, 23. Juni 2015 13:51
An: mitk-users@lists.sourceforge.net
Betreff: Re: [mitk-users] Read different volume

Hi Caspar,

this is a test case for both the issue.

For the timesteps, with the binary release is working fine also to me (all the 
timesteps are there, no crash), but I cannot manage to open it with the code I 
wrote following the tutorial (with timestep 0 is okay, but any other is 
crashing).

I also tried with the code from Matthias, but is not working.

Do you have any suggestion?

I will answer about the mirroring issue in the other thread so I won't mix up 
the two topic :)

Cheers,

Yari



Il 23.06.2015 13:17, Goch, Caspar Jonas ha scritto:
> Hi Yari,
>
> this was a test case for the mirroring issue or the dicom loading issue?
>
> Either way, I tested it in the 2015.05 binary release on Windows and just 
> dragging and dropping it works fine (all timesteps are there, no crash). I am 
> then able to segment and the surface fits the image for me.
>
> Can you confirm this using the binary release?
>
> Best,
> Caspar
>
> -----Ursprüngliche Nachricht-----
> Von: yari mattei [mailto:yari.mat...@student.supsi.ch]
> Gesendet: Dienstag, 23. Juni 2015 10:13
> An: mitk-users@lists.sourceforge.net
> Betreff: Re: [mitk-users] Read different volume
>
> Hi guys,
>
> I finally obtained a sharable example of a DICOM file which cause the problem.
>
> I put it on dropbox this is the link to download it :
>
> https://www.dropbox.com/s/sl4x4jlch3pp5gp/test_dicom_anon.dcm?dl=0
>
> I hope you find it helpful to find out what's going on :)
>
> Best,
>
> Yari
>
> Il 15.06.2015 10:44, Eisenmann, Matthias ha scritto:
>> Hi Yari,
>>
>> now I attached the file mentioned in our last mail, sorry!
>>
>> Maybe I can investigate your other questions during our next bug squashing 
>> session on Wednesday.
>> It would be great if you could double-check it with the provided code 
>> example.
>>
>> Best,
>> Matthias
>>    
>> -----Ursprüngliche Nachricht-----
>> Von: yari mattei [mailto:yari.mat...@student.supsi.ch]
>> Gesendet: Donnerstag, 11. Juni 2015 09:11
>> An: mitk-users@lists.sourceforge.net
>> Betreff: Re: [mitk-users] Read different volume
>>
>> Hi guys,
>>
>> Sorry for the late answer. I am using the 2014.10.0 release of MITK do you 
>> think the bug is present in this version? Do you think is better to work 
>> directly on the master branch?
>>
>> I unfortunately didn't recieve any attachment, is it possible for you to 
>> send it to me?
>>
>> The code of my reader is the following (sorry if I didn't share it before):
>>
>> mitk::DataNode::Pointer MyMITKDICOMReader::readPhilips3D(const char 
>> *filename){
>>        //intance of the DICOM reader
>>        mitk::DicomSeriesReader reader = mitk::DicomSeriesReader();
>>        //check if the file is a Philips 3D DICOM
>>        if (!reader.IsPhilips3DDicom(filename)){
>>            MITK_DEBUG << "THE FILE : " << filename << "IS NOT A PHILIPS 3D 
>> DICOM ! ";
>>            return NULL;
>>        }
>>
>>        mitk::StringList files = mitk::StringList();
>>        files.push_back(filename);
>>
>>        UpdateCallBackMethod callback = false;
>>
>>        mitk::Image::Pointer preLoadedImageBlock;
>>
>>        return reader.LoadDicomSeries(files, true, true, false, 
>> callback, preLoadedImageBlock); }
>>
>> Thanks for whole the help.
>>
>> Best,
>>
>> Yari
>>
>>
>> Il 03.06.2015 14:55, Eisenmann, Matthias ha scritto:
>>> Hi Yari,
>>>
>>> we had a further look at it. Since you did not provide the complete code 
>>> (your own DICOM reader is missing), we adapted the MITK Tutorial Step 3 
>>> Application (see attachment). We added the ImageTimeSelector to be 
>>> compatible with your code snippet. We could not reproduce the crash.
>>>
>>> Are you working with the current master branch?
>>> There were some problems reading 4D-DICOM data in MITK due to an ITK update 
>>> some months ago (http://bugs.mitk.org/show_bug.cgi?id=18887). But that 
>>> seems to be fixed.
>>>
>>> Can you provide your complete cpp file and your data set if updating your 
>>> code base does not help?
>>>
>>> Best,
>>> Matthias and Thomas
>>>
>>> -----Ursprüngliche Nachricht-----
>>> Von: yari mattei [mailto:yari.mat...@student.supsi.ch]
>>> Gesendet: Donnerstag, 28. Mai 2015 15:38
>>> An: mitk-users@lists.sourceforge.net
>>> Betreff: Re: [mitk-users] Read different volume
>>>
>>> Hi guys,
>>>
>>> thanks a lot, what are you saying i totally right, after the update the 
>>> data are loaded. But when I am trinyg to display the image the application 
>>> crash.
>>>
>>> The code I wrote is the following :
>>>
>>>         // Create a QApplication instance first
>>>         QApplication eco3DApp(argc, argv);
>>>         eco3DApp.setApplicationName("Eco 3D");
>>>
>>>         QmitkRegisterClasses();
>>>
>>>         mitk::StandaloneDataStorage::Pointer ds = 
>>> mitk::StandaloneDataStorage::New();
>>>
>>>         MyMITKDICOMReader myReader = MyMITKDICOMReader();
>>>
>>>         mitk::DataNode::Pointer node = 
>>> myReader.readPhilips3D("filePath");
>>>
>>>         //ds->Add(node);
>>>         mitk::Image::Pointer image = 
>>> dynamic_cast<mitk::Image*>(node->GetData());
>>>
>>>         //take a time
>>>         mitk::ImageTimeSelector::Pointer timeSelector = 
>>> mitk::ImageTimeSelector::New();
>>>
>>>         int timeStep = 1;
>>>
>>>         timeSelector->SetInput( image );
>>>         timeSelector->SetTimeNr( timeStep );
>>>         timeSelector->Update();
>>>         //timeSelector->UpdateLargestPossibleRegion();
>>>
>>>
>>>         mitk::Image::Pointer timeStepImage =
>>> timeSelector->GetOutput();
>>>
>>>         mitk::DataNode::Pointer stepImageNode = 
>>> mitk::DataNode::New();
>>>
>>>         stepImageNode->SetData(timeStepImage);
>>>         stepImageNode->Update();
>>>         ds->Add(stepImageNode);
>>>
>>>         QmitkRenderWindow renderWindow;
>>>
>>>         // Tell the RenderWindow which (part of) the datastorage to render
>>>         renderWindow.GetRenderer()->SetDataStorage(ds);
>>>
>>>         // Initialize the RenderWindow
>>>         mitk::TimeGeometry::Pointer geo =
>>> ds->ComputeBoundingGeometry3D(ds->GetAll());
>>>         mitk::RenderingManager::GetInstance()->InitializeViews(geo);
>>>
>>>         renderWindow.show();
>>>         renderWindow.resize(400, 400); //256, 256 original
>>>         renderWindow.move(QPoint(500, 100));
>>>
>>>         return eco3DApp.exec();
>>>
>>> When I launch it, it crash after the eco3DApp.exec() call, with this 
>>> error
>>>
>>> Unhandled exception at 0x020B55DA (MitkCore.dll) in AwesomeApp.exe:
>>> 0xC0000005: Access violation reading location 0x00000000.
>>>
>>> exactely in :
>>>
>>>     >
>>> MitkCore.dll!mitk::ImageDataItem::ConstructVtkImageData(itk::SmartPointer<mitk::Image
>>> const > iP) Line 234    C++
>>>
>>> line 254 is :
>>>
>>> const mitk::Vector3D vspacing = geom3d->GetSpacing();
>>>
>>> Thanks for the help.
>>>
>>> Cheers
>>> Yari
>>>
>>>
>>> Il 28.05.2015 10:12, Eisenmann, Matthias ha scritto:
>>>> Hi Yari,
>>>>
>>>> we had a look at your problem during our bug squashing session. We can 
>>>> reproduce the situation you described: After loading a 3D+t image only the 
>>>> first volume is initialized.
>>>>
>>>> Are you just wondering why this is the case or does your application crash?
>>>>
>>>> In our cases this is not a problem. The other volumes are initialized 'on 
>>>> demand' after calling the Update() method of ImageTimeSelector for a 
>>>> specific time step.
>>>>
>>>> Let us give you a pointer to a working example: The binary threshold tool 
>>>> of the segmentation plugin.
>>>> In method 
>>>> mitk::BinaryThresholdTool::CreateNewSegmentationFromThreshold(...) each 
>>>> volume of a time series is processed.
>>>>
>>>> Best,
>>>> Matthias and Thomas
>>>>
>>>> -----Ursprüngliche Nachricht-----
>>>> Von: yari mattei [mailto:yari.mat...@student.supsi.ch]
>>>> Gesendet: Montag, 18. Mai 2015 14:32
>>>> An: mitk-users@lists.sourceforge.net
>>>> Betreff: [mitk-users] Read different volume
>>>>
>>>> Hi everybody,
>>>>
>>>> I manage to open a Philips3D DICOM (with mithDicomSeriesReader) and I get 
>>>> a DataNode.
>>>>
>>>> I would like to show the 9 different time step contained in the DICOM file 
>>>> so I tried to get an image from the node with:
>>>>
>>>> mitk::Image::Pointer image =
>>>> dynamic_cast<mitk::Image*>(node->GetData());
>>>>
>>>> And to select the volume with:
>>>>
>>>>          mitk::ImageTimeSelector::Pointer time = 
>>>> mitk::ImageTimeSelector::New();
>>>>
>>>>          time->SetInput(image);
>>>>          time->SetTimeNr(1);
>>>>          time->Update();
>>>>
>>>>          mitk::Image::Pointer image4 = time->GetOutput();
>>>>
>>>>
>>>>          mitk::StandaloneDataStorage::Pointer ds4 = 
>>>> mitk::StandaloneDataStorage::New();
>>>>          mitk::DataNode::Pointer node4 = mitk::DataNode::New();
>>>>
>>>>          node4->SetData(image4);
>>>>
>>>>          ds4->Add(node4);
>>>>
>>>> This works only if I set the TimeNr to 0. I check with the debugger the 
>>>> value of the image and I see that there are 9 different volume but only 
>>>> the first one has values inside (the others are NULL).
>>>> This is part of the dump of the debugger :
>>>> -        image    {m_Pointer=0x164978e0 {m_Channels={ size=1 }
>>>> m_Volumes={ size=9 } m_Slices={ size=1872 } ...} } 
>>>> itk::SmartPointer<mitk::Image>
>>>>          -        m_Pointer    0x164978e0 {m_Channels={ size=1 } 
>>>> m_Volumes={
>>>> size=9 } m_Slices={ size=1872 } ...}    mitk::Image *
>>>>              +        [mitk::Image]    {m_Channels={ size=1 } m_Volumes={
>>>> size=9 } m_Slices={ size=1872 } ...} MitkCore.dll!mitk::Image
>>>>              +        mitk::SlicedData
>>>> {m_LargestPossibleRegion={m_Index={m_Index=0x16497984 {0, 0, 0, 0, 
>>>> 0} }
>>>> m_Size={m_Size=0x16497998 {224, ...} } } ...} mitk::SlicedData
>>>>              +        m_Channels    { size=1 }
>>>> std::vector<itk::SmartPointer<mitk::ImageDataItem>,std::allocator<itk::SmartPointer<mitk::ImageDataItem>
>>>>      > >
>>>>              -        m_Volumes    { size=9 }
>>>> std::vector<itk::SmartPointer<mitk::ImageDataItem>,std::allocator<itk::SmartPointer<mitk::ImageDataItem>
>>>>      > >
>>>>                              [size]    9    int
>>>>                              [capacity]    9    int
>>>>                    +        [0]    {m_Pointer=0x1641ba88 {m_Data=0x235b0040
>>>> "" m_PixelType=0x164af8a8 {m_ComponentType=1 m_PixelType=SCALAR (1) ...} 
>>>> ...} } itk::SmartPointer<mitk::ImageDataItem>
>>>>                    +        [1]    {m_Pointer=0x00000000 <NULL> }
>>>> itk::SmartPointer<mitk::ImageDataItem>
>>>>                    +        [2]    {m_Pointer=0x00000000 <NULL> }
>>>> itk::SmartPointer<mitk::ImageDataItem>
>>>>                    +        [3]    {m_Pointer=0x00000000 <NULL> }
>>>> itk::SmartPointer<mitk::ImageDataItem>
>>>>                      .......
>>>>
>>>>
>>>> Does anyone have any idea of what cause di problem?
>>>>
>>>> Thanks in advance
>>>>
>>>> Yari
>>>>
>>>> -------------------------------------------------------------------
>>>> -
>>>> -
>>>> -
>>>> -------- One dashboard for servers and applications across 
>>>> Physical-Virtual-Cloud Widest out-of-the-box monitoring support with 50+ 
>>>> applications Performance metrics, stats and reports that give you 
>>>> Actionable Insights Deep dive visibility with transaction tracing using 
>>>> APM Insight.
>>>> http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
>>>> _______________________________________________
>>>> mitk-users mailing list
>>>> mitk-users@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/mitk-users
>>> --------------------------------------------------------------------
>>> -
>>> -
>>> -------- _______________________________________________
>>> mitk-users mailing list
>>> mitk-users@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/mitk-users
>> ---------------------------------------------------------------------
>> -
>> -------- _______________________________________________
>> mitk-users mailing list
>> mitk-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/mitk-users
>
> ----------------------------------------------------------------------
> -------- Monitor 25 network devices or servers for free with 
> OpManager!
> OpManager is web-based network management software that monitors 
> network devices and physical & virtual servers, alerts via email & sms 
> for fault. Monitor 25 devices for free with no restriction. Download 
> now http://ad.doubleclick.net/ddm/clk/292181274;119417398;o
> _______________________________________________
> mitk-users mailing list
> mitk-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/mitk-users


------------------------------------------------------------------------------
Monitor 25 network devices or servers for free with OpManager!
OpManager is web-based network management software that monitors network 
devices and physical & virtual servers, alerts via email & sms for fault. 
Monitor 25 devices for free with no restriction. Download now 
http://ad.doubleclick.net/ddm/clk/292181274;119417398;o
_______________________________________________
mitk-users mailing list
mitk-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mitk-users

------------------------------------------------------------------------------
Monitor 25 network devices or servers for free with OpManager!
OpManager is web-based network management software that monitors 
network devices and physical & virtual servers, alerts via email & sms 
for fault. Monitor 25 devices for free with no restriction. Download now
http://ad.doubleclick.net/ddm/clk/292181274;119417398;o
_______________________________________________
mitk-users mailing list
mitk-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mitk-users

Reply via email to