DICOM @ OFFIS

Discussion Forum for OFFIS DICOM Tools - For registration, send email with desired user name to the OFFIS DICOM team
It is currently Thu, 2017-05-25, 11:44

All times are UTC + 1 hour




Post new topic Reply to topic  [ 22 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Waveform (DICOM-ECG)
PostPosted: Tue, 2008-07-01, 17:04 
Offline

Joined: Tue, 2008-07-01, 16:54
Posts: 13
Location: Nancy France
Hi,
I would like to implement a reader DICOM-ECG. But I don't know where I must start :oops:
What object may I use for waveform ?
(e.g. for Image is DicomImage* but for Waveform ?)
thanks,

Anth


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2008-07-02, 16:59 
Offline
DCMTK Developer

Joined: Fri, 2004-11-05, 13:47
Posts: 1549
Location: Oldenburg, Germany
Hi Anth,

at the moment there is no official specific support for DICOM Waveform objects in DCMTK. Of course you can read and access all values (like Patient Name, Number of Channels in ECG File etc) by using DCMTK's standard routines in dcmdata, but there is no API (-> no specific module like for Presentation states "dcmprstat") that helps you accessing calibrated sample values or letting you dump sample values nicely to console.

However, we have an internal module with an API for reading, accessing, modifying and writing Waveform objects, but this ist not well-tested and therefore not part of the public toolkit.

If you are interested, I can send you a download link for that module (after some code cleanups), maybe middle or end of next week. But of course that code is only in alpha stage at the moment so you should not use that in serious applications at this time. So, you would be a beta tester :-)

Regards,
Michael


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2008-07-02, 17:50 
Offline

Joined: Tue, 2008-07-01, 16:54
Posts: 13
Location: Nancy France
Hi Michael,

I would be interested in your internal module with an API for reading Waveform objects.

I've not been interested for modifying and writing Waveform objects, yet.

If I will use it, I would accept to be a beta tester.

My application is used on MAC intel and PPC, into Tiger and Leopard.

Regards

Anth


Top
 Profile  
 
 Post subject:
PostPosted: Mon, 2008-07-07, 11:42 
Offline
DCMTK Developer

Joined: Fri, 2004-11-05, 13:47
Posts: 1549
Location: Oldenburg, Germany
Hi,

what functionality do you need regarding Waveform Objects? Just reading Sampling Frequency etc?

I will send you an email as far as I have some code to share.

Regards,
Michael


Top
 Profile  
 
 Post subject:
PostPosted: Mon, 2008-07-07, 13:05 
Offline

Joined: Tue, 2008-07-01, 16:54
Posts: 13
Location: Nancy France
Hi,

I just need plotting the waveform (ECG). So I need to get the sample time interval, the multiplier for amplitude value, value of waveform samples and where the leads (I, II, III, aVr, V1, V2...) start and finish.
I know the format SCP-ECG with Huffmann, bimodal, ...

Regards,

Anthony


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2008-07-23, 17:09 
Offline

Joined: Tue, 2008-07-01, 16:54
Posts: 13
Location: Nancy France
Hi,

I try to make a DICOM-ECG viewer.

I have got :

Quote:
0002,0002 => Media Storage SOP Class UID
1.2.840.10008.5.1.4.1.1.9.2.1 => Hemodynamic Waveform Storage

0008,0060 => Modality
45 43 47 20 => ECG

003A,0004 => Waveform
Originality ORIGINAL /DERIVED
4F 52 49 47 49 4E 41 4C => ORIGINAL

003A,0005 => Number of Waveform Channels [1..24]
0C 00 => 12

003A,0010 => Number of Waveform Samples
60 09 00 00 => 2400

003A,001A => Sampling Frequency [200; 1000]
32 34 30 20 => 240

0008,0100 => Code Value
35 2E 36 2E 33 2D 39 2D 31 20 => 5.6.3-9-1

0008,0102 => Coding Scheme Designator
53 43 50 45 43 47 => SCPECG

0008,0103 => Coding Scheme Version
31 2E 33 20 => 1.3

0008,0104 => Code Meaning
4C 65 61 64 20 49 => Lead I

003A,0212 => Channel Sensitivity Correction Factor
31 20 => 1

003A,0213 => Channel Baseline
30 20 => 0

003A,0214 => Channel Time Skew
30 20 => 0

003A,021A => Waveform Bits Stored
10 00 => 16

003A,0220 => Filter Low Frequency
2E 30 35 20 => .05

003A,0221 => Filter High Frequency
31 30 30 20 => 100

5400,1004 => Waveform Bits Allocated
10 00 => 16

5400,1006 => Waveform Sample Interpretation
53 53 => SS

5400,100A => Waveform Padding Value
00 80 => 8000

5400,1010 => Waveform Data
00 E1 00 00 => 0x0000E100 => 57600
BA 00 30 00 76 FF 8B FF A2 00 D3 FF AE FF
50 FF 62 00 C4 00 1E 01 C2 00 BA 00 30 00 76 FF
8B FF A2 00 D3 FF B2 FF 58 FF 64 00 C2 00 22 01
C2 00 AE 00 2E 00 80 FF 92 FF 97 00 D7 FF B6 FF
60 FF 58 00 B0 00 00 01 AE 00 A8 00 2A 00 82 FF
97 FF 93 00 D6 FF BA FF 68 FF 56 00 A6 00 F6 00
A6 00 9C 00 24 00 88 FF A0 FF 8A 00 D6 FF BE FF
74 FF 52 00 A2 00 F0 00 A2 00 98 00 26 00 8E FF
A1 FF 85 00 DA FF C4 FF 7A FF 4E 00 9C 00 EC 00


It's easy to get them with you library.

So I plotted the points (x y) :

Quote:
BA00 => 0.004167 -17.920000
3000 => 0.008333 12.288000
76FF => 0.012500 30.462999
8BFF => 0.016667 -29.697001
A200 => 0.020833 -24.063999
D3FF => 0.025000 -11.265000
AEFF => 0.029167 -20.737000
50FF => 0.033333 20.735001
6200 => 0.037500 25.087999
...


Unfortunately it's seem wrong. It's don't look like a ECG.
Do you know what should I do ?

Best regards,

Anthony


Top
 Profile  
 
 Post subject:
PostPosted: Thu, 2008-07-24, 16:27 
Offline

Joined: Tue, 2008-07-01, 16:54
Posts: 13
Location: Nancy France
My plots are more looking like a ECG, but it's not been right, yet !

I thought :
BA00 => t1 for channel 1
3000 => t2 for channel 1
76FF => t3 for channel 1
8BFF => t4 for channel 1
A200 => t5 for channel 1
D3FF => t6 for channel 1
AEFF => t7 for channel 1
50FF => t8 for channel 1
6200 => t9 for channel 1
...

But it's:
BA00 => t1 for channel 1
3000 => t1 for channel 2
76FF => t1 for channel 3
8BFF => t1 for channel 4
A200 => t1 for channel 5
D3FF => t1 for channel 6
AEFF => t1 for channel 7
50FF => t2 for channel 1
6200 => t2 for channel 2
...


Top
 Profile  
 
 Post subject:
PostPosted: Fri, 2008-07-25, 11:19 
Offline
DCMTK Developer

Joined: Fri, 2004-11-05, 13:47
Posts: 1549
Location: Oldenburg, Germany
Hi,

if you like to, send the file to dicom (at) offis (dot) de and I'll return the waveform values as dumped by our (currently internal) Waveform dump (wvfdump) tool.

Regards,
Michael


Top
 Profile  
 
 Post subject:
PostPosted: Fri, 2008-07-25, 14:26 
Offline
DCMTK Developer

Joined: Fri, 2004-11-05, 13:47
Posts: 1549
Location: Oldenburg, Germany
Hi,

I've sent you an email with the sample values for all of the channels. As you realized in your last posting, the waveform data is stored round-robin in the attribute Waveform Data, so actually there channel's samples are stored like that (example with 3 channels A,B and C): A1B1C1A2B2C2A3B3C3...

That results for your specific files into the following (first 5) final values for the (first 3) channels:

Channel 1: 0.22692 0.22692 0.21228 0.20496 0.19032
Channel 2: 0.05856 0.05856 0.05612 0.05124 0.04392
Channel 3: -0.16836 -0.16836 -0.15616 -0.15372 -0.1464

Actually stored (raw data) in the file are the following values (for complete dump see email attachment):

Channel 1: 186 186 174 168 156
Channel 2: 48 48 46 42 36
Channel 3: -138 -138 -128

I did not check your plotting.

I cannot guarantee for my beta application's results, but I hope those values make sense for an ECG.

Regards,
Michael


Top
 Profile  
 
 Post subject: Waveform Data
PostPosted: Mon, 2009-08-03, 06:37 
Offline

Joined: Fri, 2009-07-31, 11:39
Posts: 1
Dear Michael ,

Even I am developing a Ecg veiwer.
I have few questions
1. After we extract the data from group element 5400,1010 this is in the form of single array,how do we get the data for 12 leads in the form of amplitude and frequency (y and x axes ) is this data a integer or floating point.

2 Assuming we have the data in the form of array how to plot the graph
I mean what parameters we need to have apart from amplitude and frequency.

3 If you have any article regarding plotting data it would be very helpful.

Thanks

_________________
Amey Deshpande


Top
 Profile  
 
 Post subject: Re: Waveform (DICOM-ECG)
PostPosted: Fri, 2010-01-22, 08:34 
Offline

Joined: Mon, 2008-10-20, 12:07
Posts: 5
ancrou wrote:
Hi,
I would like to implement a reader DICOM-ECG. But I don't know where I must start :oops:
What object may I use for waveform ?
(e.g. for Image is DicomImage* but for Waveform ?)
thanks,

Anth


An bcb program using "cdtk" draw ecg data

http://www.charruasoft.com/ecgviewer/ecgviewer.zip


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2011-07-13, 15:16 
Offline

Joined: Tue, 2011-07-05, 19:23
Posts: 1
Location: Argentina
Hi Michael
I am interested in creating a DICOM ECG file from an ECG text format. I have read in this forum that by the year 2008 there wasnt an official specific support for DICOM Waveform yet, however I was hopping that there is one.
Altought I would like to ask you if you know about any tool that could help me in this issue.
Thanks in advance.

Alejandra


Top
 Profile  
 
 Post subject:
PostPosted: Tue, 2011-08-02, 12:02 
Offline
DCMTK Developer

Joined: Fri, 2004-11-05, 13:47
Posts: 1549
Location: Oldenburg, Germany
Hi,

we do not have a converter tool for any ECG format to DICOM. We have a library called "dcmwave" which helps writing programs for creating, modifying and storing DICOM waveform files. I is not published yet, which we can give away for testing, if you like. In case, mail to dicom at offis dot de.

There is also a library called biosig which reads many signal data formats. However, as far as I know they do not import/export DICOM yet.

Michael


Top
 Profile  
 
 Post subject:
PostPosted: Wed, 2011-11-09, 15:36 
Biosig? Never heard of that. Need to give it a look. When are you planning to publish dcmwave?


Last edited by Tipsacon on Fri, 2011-11-18, 21:44, edited 1 time in total.

Top
  
 
 Post subject:
PostPosted: Wed, 2011-11-09, 19:05 
Offline
DCMTK Developer

Joined: Fri, 2004-11-05, 13:47
Posts: 1549
Location: Oldenburg, Germany
Sorry, I don't know. We decided to do it but it should have some polishing before -- when it's done, it's done :) We will post an update here, then.

Michael


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 22 posts ]  Go to page 1, 2  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group