Rocksolid Light

Welcome to Rocksolid Light

mail  files  register  newsreader  groups  login

Message-ID:  

Computers are useless. They can only give you answers. -- Pablo Picasso


devel / comp.protocols.dicom / Re: DICOM SR Template Preparation

SubjectAuthor
* DICOM SR Template PreparationYusuf CELIK
`* DICOM SR Template PreparationDavid Clunie
 `* DICOM SR Template PreparationYusuf CELIK
  `* DICOM SR Template PreparationDavid Clunie
   +* DICOM SR Template PreparationChris Bridge
   |`* DICOM SR Template PreparationSean Doyle
   | +* DICOM SR Template PreparationChris Bridge
   | |`- DICOM SR Template PreparationYusuf CELIK
   | `* DICOM SR Template PreparationYusuf CELIK
   |  `* DICOM SR Template PreparationJörg_Riesmeier
   |   `- DICOM SR Template PreparationStephen Douglas Scotti
   `- DICOM SR Template PreparationYusuf CELIK

1
Re: DICOM SR Template Preparation

<dc2336dc-f163-4a1a-acf0-132c010ae784n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=652&group=comp.protocols.dicom#652

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:ac8:4e51:0:b0:3e6:720f:badc with SMTP id e17-20020ac84e51000000b003e6720fbadcmr3537119qtw.2.1681210584612;
Tue, 11 Apr 2023 03:56:24 -0700 (PDT)
X-Received: by 2002:ac8:7f84:0:b0:3e1:5755:7bbf with SMTP id
z4-20020ac87f84000000b003e157557bbfmr4858842qtj.5.1681210584275; Tue, 11 Apr
2023 03:56:24 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Tue, 11 Apr 2023 03:56:24 -0700 (PDT)
In-Reply-To: <cb8dd048-1e05-415f-9bbe-1c0c686d7958n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2001:4bb8:192:31e1:f0c8:e409:46f8:542c;
posting-account=YFi_UAoAAACTPXmZqt1QuJHF4fLwCPfF
NNTP-Posting-Host: 2001:4bb8:192:31e1:f0c8:e409:46f8:542c
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com> <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
<0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com> <504373a9-3673-426e-997a-dc515ce50a0dn@googlegroups.com>
<cb8dd048-1e05-415f-9bbe-1c0c686d7958n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <dc2336dc-f163-4a1a-acf0-132c010ae784n@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: stephen.d.scotti@gmail.com (Stephen Douglas Scotti)
Injection-Date: Tue, 11 Apr 2023 10:56:24 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2725
 by: Stephen Douglas Scot - Tue, 11 Apr 2023 10:56 UTC

I found this thread while looking for information about: https://github.com/ImagingDataCommons/highdicom

regarding structured reports creation and also about key object creation, I think in this reference:

https://www.dicomstandard.org/News-dir/ftsup/docs/sups/sup59.pdf

I'm been using Orthanc for a few years, and I'm a little familiar with the MedDream viewer. I think that MedDream implements KEY OBJECTS in their viewer for saving instances of interest.

That would be a nice addition to Orthanc because I do not believe that it implements that yet, at least with the base installation. It may be that there are C++ Plug-in or Python Plug-ins that have been developed to support that.

I'd also like to start creating SR's for radiology reports instead of attaching encapsulted PDF's to studies . It seems like highdicom already has tools for that ? Orthanc has a Python Plug-in that makes it pretty easy to add features to Orthanc using that, although a C++ version would probably be better eventually.

Stephen D. Scotti

DICOM SR Template Preparation

<4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1421&group=comp.protocols.dicom#1421

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:ae9:ec0a:0:b0:706:517b:305 with SMTP id h10-20020ae9ec0a000000b00706517b0305mr1351411qkg.625.1674450629997;
Sun, 22 Jan 2023 21:10:29 -0800 (PST)
X-Received: by 2002:a81:4e85:0:b0:4f7:b1e:61e7 with SMTP id
c127-20020a814e85000000b004f70b1e61e7mr1931949ywb.172.1674450629837; Sun, 22
Jan 2023 21:10:29 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Sun, 22 Jan 2023 21:10:29 -0800 (PST)
Injection-Info: google-groups.googlegroups.com; posting-host=78.187.44.157; posting-account=yx9n7QkAAACUcKfLGnjbEZV3PHuIQp03
NNTP-Posting-Host: 78.187.44.157
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
Subject: DICOM SR Template Preparation
From: agymtcelik11@gmail.com (Yusuf CELIK)
Injection-Date: Mon, 23 Jan 2023 05:10:29 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 1539
 by: Yusuf CELIK - Mon, 23 Jan 2023 05:10 UTC

Hi everyone,

I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?

Thank you.

Re: DICOM SR Template Preparation

<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1422&group=comp.protocols.dicom#1422

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a37:c13:0:b0:706:427f:5223 with SMTP id 19-20020a370c13000000b00706427f5223mr607729qkm.457.1674477503966;
Mon, 23 Jan 2023 04:38:23 -0800 (PST)
X-Received: by 2002:a25:bd54:0:b0:7d3:851c:e744 with SMTP id
p20-20020a25bd54000000b007d3851ce744mr2966132ybm.84.1674477503782; Mon, 23
Jan 2023 04:38:23 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 04:38:23 -0800 (PST)
In-Reply-To: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=50.32.167.109; posting-account=rKkGZwkAAADOuxQ23uuHnmKt95j-5iL6
NNTP-Posting-Host: 50.32.167.109
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: dclunie@dclunie.com (David Clunie)
Injection-Date: Mon, 23 Jan 2023 12:38:23 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2116
 by: David Clunie - Mon, 23 Jan 2023 12:38 UTC

On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:

> I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?

Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:

https://link.springer.com/article/10.1007/s10278-022-00683-y
https://github.com/ImagingDataCommons/highdicom

David

Re: DICOM SR Template Preparation

<f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1424&group=comp.protocols.dicom#1424

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a37:ef06:0:b0:705:cfba:3af9 with SMTP id j6-20020a37ef06000000b00705cfba3af9mr1059044qkk.676.1674477947233;
Mon, 23 Jan 2023 04:45:47 -0800 (PST)
X-Received: by 2002:a81:4984:0:b0:4fb:3501:6d9e with SMTP id
w126-20020a814984000000b004fb35016d9emr2184957ywa.454.1674477947023; Mon, 23
Jan 2023 04:45:47 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 04:45:46 -0800 (PST)
In-Reply-To: <41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=78.187.44.157; posting-account=yx9n7QkAAACUcKfLGnjbEZV3PHuIQp03
NNTP-Posting-Host: 78.187.44.157
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com> <41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: agymtcelik11@gmail.com (Yusuf CELIK)
Injection-Date: Mon, 23 Jan 2023 12:45:47 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2941
 by: Yusuf CELIK - Mon, 23 Jan 2023 12:45 UTC

23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
>
> > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
>
> https://link.springer.com/article/10.1007/s10278-022-00683-y
> https://github.com/ImagingDataCommons/highdicom
>
> David

Hi David

On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.

Re: DICOM SR Template Preparation

<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1425&group=comp.protocols.dicom#1425

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a05:620a:25a:b0:6ff:ca92:2678 with SMTP id q26-20020a05620a025a00b006ffca922678mr720289qkn.612.1674480313677;
Mon, 23 Jan 2023 05:25:13 -0800 (PST)
X-Received: by 2002:a81:5388:0:b0:4f9:1655:8ffb with SMTP id
h130-20020a815388000000b004f916558ffbmr1770757ywb.238.1674480313422; Mon, 23
Jan 2023 05:25:13 -0800 (PST)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 05:25:13 -0800 (PST)
In-Reply-To: <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=50.32.167.109; posting-account=rKkGZwkAAADOuxQ23uuHnmKt95j-5iL6
NNTP-Posting-Host: 50.32.167.109
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: dclunie@dclunie.com (David Clunie)
Injection-Date: Mon, 23 Jan 2023 13:25:13 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: David Clunie - Mon, 23 Jan 2023 13:25 UTC

As you know, for referencing an ROI that spans multiple slices, how to encode that using TID 1500 depends on whether you are referencing a SEG that defines the ROI as bit planes, or using contours within the SR itself defined inside TID 1411 Volumetric ROI Measurements and Qualitative Evaluations using 2D or 3D coordinates; it sounds like you are using the last of the three choices.

If you are concerned about support for 3D coordinates and Comprehensive3DSR among recipients, then map the 3D coordinates to 2D image-relative coordinates yourself and send those instead. It may be that highdicom doesn't have a lot of support for 3D ROIs with 2D coordinates due to the preferences and priorities of some of its developers, but I am not sure.

If highdicom s currently insufficient, then you can fork and fix it yourself since it is open source, or contact one of the developers and discuss it with them. That is probably easier than starting from scratch yourself. That said, what you are asking for sounds straightforward, and again, the highdicom developers may be able to help you if the documentation does not (yet) cover your use case.

Creating a populated template from scratch, whether it be programmatically or declaratively in some sort of toolkit-specific JSON or XML, and then using dcmtk or PixelMed tools to convert the latter to DICOM binary encoding is quite painful, which is why tools like highdicom (and dcmqi before that) exist. We did try to "standardize" the declarative approach using JSON in Supplement 219 to make this easier, and it is available as a frozen draft (and implemented in my PixelMed toolkit), but it hasn't progressed to final text due to limited interest from the AI developer community and lack of other implementations. You are welcome to try it though (https://www.dclunie.com/dicom-status/status.html#supplement219).

Whatever you do, make sure you validate your encoded results using both dciodvfy and DicomSRValidator from PixelMed.

David

On Monday, January 23, 2023 at 7:45:48 AM UTC-5, Yusuf CELIK wrote:
> 23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl....@dclunie.com şunları yazdı:
> > On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
> >
> > > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> > Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
> >
> > https://link.springer.com/article/10.1007/s10278-022-00683-y
> > https://github.com/ImagingDataCommons/highdicom
> >
> > David
> Hi David
>
> On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.

Re: DICOM SR Template Preparation

<193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1427&group=comp.protocols.dicom#1427

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:ad4:402b:0:b0:534:9cc9:63b with SMTP id q11-20020ad4402b000000b005349cc9063bmr837546qvp.62.1674483783392;
Mon, 23 Jan 2023 06:23:03 -0800 (PST)
X-Received: by 2002:a81:a0c1:0:b0:462:b9d0:c8b with SMTP id
x184-20020a81a0c1000000b00462b9d00c8bmr3010739ywg.345.1674483783139; Mon, 23
Jan 2023 06:23:03 -0800 (PST)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 06:23:02 -0800 (PST)
In-Reply-To: <f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=132.183.4.6; posting-account=Tw522QoAAABqM4iIwIhjlDaBWW3oLM0W
NNTP-Posting-Host: 132.183.4.6
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: chrisbridge44@googlemail.com (Chris Bridge)
Injection-Date: Mon, 23 Jan 2023 14:23:03 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: Chris Bridge - Mon, 23 Jan 2023 14:23 UTC

On Monday, 23 January 2023 at 08:25:15 UTC-5, dcl...@dclunie.com wrote:
> As you know, for referencing an ROI that spans multiple slices, how to encode that using TID 1500 depends on whether you are referencing a SEG that defines the ROI as bit planes, or using contours within the SR itself defined inside TID 1411 Volumetric ROI Measurements and Qualitative Evaluations using 2D or 3D coordinates; it sounds like you are using the last of the three choices.
>
> If you are concerned about support for 3D coordinates and Comprehensive3DSR among recipients, then map the 3D coordinates to 2D image-relative coordinates yourself and send those instead. It may be that highdicom doesn't have a lot of support for 3D ROIs with 2D coordinates due to the preferences and priorities of some of its developers, but I am not sure.
>
> If highdicom s currently insufficient, then you can fork and fix it yourself since it is open source, or contact one of the developers and discuss it with them. That is probably easier than starting from scratch yourself. That said, what you are asking for sounds straightforward, and again, the highdicom developers may be able to help you if the documentation does not (yet) cover your use case.
>
> Creating a populated template from scratch, whether it be programmatically or declaratively in some sort of toolkit-specific JSON or XML, and then using dcmtk or PixelMed tools to convert the latter to DICOM binary encoding is quite painful, which is why tools like highdicom (and dcmqi before that) exist. We did try to "standardize" the declarative approach using JSON in Supplement 219 to make this easier, and it is available as a frozen draft (and implemented in my PixelMed toolkit), but it hasn't progressed to final text due to limited interest from the AI developer community and lack of other implementations. You are welcome to try it though (https://www.dclunie..com/dicom-status/status.html#supplement219).
>
> Whatever you do, make sure you validate your encoded results using both dciodvfy and DicomSRValidator from PixelMed.
>
> David
> On Monday, January 23, 2023 at 7:45:48 AM UTC-5, Yusuf CELIK wrote:
> > 23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> > > On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
> > >
> > > > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> > > Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
> > >
> > > https://link.springer.com/article/10.1007/s10278-022-00683-y
> > > https://github.com/ImagingDataCommons/highdicom
> > >
> > > David
> > Hi David
> >
> > On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.

Hi Yusuf,

I am one of the developers of highdicom. I'm afraid that I don't understand what is currently missing in highdicom that you require. Almost all elements of TID 1500 are there in Python classes. What is this "Annex" that you are referring to?

I know that currently the documentation for highdicom is a little lacking . However there is a branch that I have been working on with a much improved user guide. The branch is called "seg_explanation" but also covers SR. I suggest you see whether the documentation on that branch may explain things better. Specifically these files (though it may be better to build the html docs yourself to make them readable in a browser as intended, see the developer guide for instrucitons to build the docs):

General SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/generalsr.rst
Creating TID1500 SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/tid1500.rst

Hope this helps. If you have more specific questions, I'm happy to try and answer.

Best,
Chris

Re: DICOM SR Template Preparation

<0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1428&group=comp.protocols.dicom#1428

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a05:620a:15eb:b0:6fb:7c45:bd5 with SMTP id p11-20020a05620a15eb00b006fb7c450bd5mr1369271qkm.304.1674484443371;
Mon, 23 Jan 2023 06:34:03 -0800 (PST)
X-Received: by 2002:a25:4b41:0:b0:803:e799:d7b9 with SMTP id
y62-20020a254b41000000b00803e799d7b9mr1015524yba.16.1674484443095; Mon, 23
Jan 2023 06:34:03 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 06:34:02 -0800 (PST)
In-Reply-To: <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=173.48.194.186; posting-account=b8OKaQoAAABy-WKaLsYnikgvICqnFVBf
NNTP-Posting-Host: 173.48.194.186
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com> <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: sdoyle@gmail.com (Sean Doyle)
Injection-Date: Mon, 23 Jan 2023 14:34:03 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 7034
 by: Sean Doyle - Mon, 23 Jan 2023 14:34 UTC

Hi Yusuf -

Dave Clunie's suggestion of using 2D coordinates in a Comprehensive 3D TID 1500 does work - this is what I used in the RSNA IAIP showcase last November. The images can be displayed in both the Fovia viewer and in the OHIF v3 stable branch.

Sean

On Monday, January 23, 2023 at 9:23:05 AM UTC-5, Chris Bridge wrote:
> On Monday, 23 January 2023 at 08:25:15 UTC-5, dcl...@dclunie.com wrote:
> > As you know, for referencing an ROI that spans multiple slices, how to encode that using TID 1500 depends on whether you are referencing a SEG that defines the ROI as bit planes, or using contours within the SR itself defined inside TID 1411 Volumetric ROI Measurements and Qualitative Evaluations using 2D or 3D coordinates; it sounds like you are using the last of the three choices.
> >
> > If you are concerned about support for 3D coordinates and Comprehensive3DSR among recipients, then map the 3D coordinates to 2D image-relative coordinates yourself and send those instead. It may be that highdicom doesn't have a lot of support for 3D ROIs with 2D coordinates due to the preferences and priorities of some of its developers, but I am not sure.
> >
> > If highdicom s currently insufficient, then you can fork and fix it yourself since it is open source, or contact one of the developers and discuss it with them. That is probably easier than starting from scratch yourself. That said, what you are asking for sounds straightforward, and again, the highdicom developers may be able to help you if the documentation does not (yet) cover your use case.
> >
> > Creating a populated template from scratch, whether it be programmatically or declaratively in some sort of toolkit-specific JSON or XML, and then using dcmtk or PixelMed tools to convert the latter to DICOM binary encoding is quite painful, which is why tools like highdicom (and dcmqi before that) exist. We did try to "standardize" the declarative approach using JSON in Supplement 219 to make this easier, and it is available as a frozen draft (and implemented in my PixelMed toolkit), but it hasn't progressed to final text due to limited interest from the AI developer community and lack of other implementations. You are welcome to try it though (https://www.dclunie.com/dicom-status/status.html#supplement219).
> >
> > Whatever you do, make sure you validate your encoded results using both dciodvfy and DicomSRValidator from PixelMed.
> >
> > David
> > On Monday, January 23, 2023 at 7:45:48 AM UTC-5, Yusuf CELIK wrote:
> > > 23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> > > > On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
> > > >
> > > > > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> > > > Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
> > > >
> > > > https://link.springer.com/article/10.1007/s10278-022-00683-y
> > > > https://github.com/ImagingDataCommons/highdicom
> > > >
> > > > David
> > > Hi David
> > >
> > > On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.
> Hi Yusuf,
>
> I am one of the developers of highdicom. I'm afraid that I don't understand what is currently missing in highdicom that you require. Almost all elements of TID 1500 are there in Python classes. What is this "Annex" that you are referring to?
>
> I know that currently the documentation for highdicom is a little lacking . However there is a branch that I have been working on with a much improved user guide. The branch is called "seg_explanation" but also covers SR. I suggest you see whether the documentation on that branch may explain things better. Specifically these files (though it may be better to build the html docs yourself to make them readable in a browser as intended, see the developer guide for instrucitons to build the docs):
>
> General SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/generalsr.rst
> Creating TID1500 SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/tid1500.rst
>
> Hope this helps. If you have more specific questions, I'm happy to try and answer.
>
> Best,
> Chris

Re: DICOM SR Template Preparation

<6a82f778-1480-434e-9b2c-ebfeda5f27c2n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1431&group=comp.protocols.dicom#1431

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a05:6214:5784:b0:537:4bc1:d779 with SMTP id lv4-20020a056214578400b005374bc1d779mr491935qvb.121.1674523779832;
Mon, 23 Jan 2023 17:29:39 -0800 (PST)
X-Received: by 2002:a81:16cc:0:b0:506:3cd3:7e42 with SMTP id
195-20020a8116cc000000b005063cd37e42mr59073yww.454.1674523779466; Mon, 23 Jan
2023 17:29:39 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 17:29:39 -0800 (PST)
In-Reply-To: <0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=73.69.139.147; posting-account=Tw522QoAAABqM4iIwIhjlDaBWW3oLM0W
NNTP-Posting-Host: 73.69.139.147
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com> <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
<0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <6a82f778-1480-434e-9b2c-ebfeda5f27c2n@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: chrisbridge44@googlemail.com (Chris Bridge)
Injection-Date: Tue, 24 Jan 2023 01:29:39 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 8306
 by: Chris Bridge - Tue, 24 Jan 2023 01:29 UTC

On Monday, 23 January 2023 at 09:34:05 UTC-5, sdo...@gmail.com wrote:
> Hi Yusuf -
>
> Dave Clunie's suggestion of using 2D coordinates in a Comprehensive 3D TID 1500 does work - this is what I used in the RSNA IAIP showcase last November. The images can be displayed in both the Fovia viewer and in the OHIF v3 stable branch.
>
> Sean
> On Monday, January 23, 2023 at 9:23:05 AM UTC-5, Chris Bridge wrote:
> > On Monday, 23 January 2023 at 08:25:15 UTC-5, dcl...@dclunie.com wrote:
> > > As you know, for referencing an ROI that spans multiple slices, how to encode that using TID 1500 depends on whether you are referencing a SEG that defines the ROI as bit planes, or using contours within the SR itself defined inside TID 1411 Volumetric ROI Measurements and Qualitative Evaluations using 2D or 3D coordinates; it sounds like you are using the last of the three choices.
> > >
> > > If you are concerned about support for 3D coordinates and Comprehensive3DSR among recipients, then map the 3D coordinates to 2D image-relative coordinates yourself and send those instead. It may be that highdicom doesn't have a lot of support for 3D ROIs with 2D coordinates due to the preferences and priorities of some of its developers, but I am not sure.
> > >
> > > If highdicom s currently insufficient, then you can fork and fix it yourself since it is open source, or contact one of the developers and discuss it with them. That is probably easier than starting from scratch yourself. That said, what you are asking for sounds straightforward, and again, the highdicom developers may be able to help you if the documentation does not (yet) cover your use case.
> > >
> > > Creating a populated template from scratch, whether it be programmatically or declaratively in some sort of toolkit-specific JSON or XML, and then using dcmtk or PixelMed tools to convert the latter to DICOM binary encoding is quite painful, which is why tools like highdicom (and dcmqi before that) exist. We did try to "standardize" the declarative approach using JSON in Supplement 219 to make this easier, and it is available as a frozen draft (and implemented in my PixelMed toolkit), but it hasn't progressed to final text due to limited interest from the AI developer community and lack of other implementations. You are welcome to try it though (https://www.dclunie.com/dicom-status/status.html#supplement219).
> > >
> > > Whatever you do, make sure you validate your encoded results using both dciodvfy and DicomSRValidator from PixelMed.
> > >
> > > David
> > > On Monday, January 23, 2023 at 7:45:48 AM UTC-5, Yusuf CELIK wrote:
> > > > 23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> > > > > On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
> > > > >
> > > > > > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> > > > > Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
> > > > >
> > > > > https://link.springer.com/article/10.1007/s10278-022-00683-y
> > > > > https://github.com/ImagingDataCommons/highdicom
> > > > >
> > > > > David
> > > > Hi David
> > > >
> > > > On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.
> > Hi Yusuf,
> >
> > I am one of the developers of highdicom. I'm afraid that I don't understand what is currently missing in highdicom that you require. Almost all elements of TID 1500 are there in Python classes. What is this "Annex" that you are referring to?
> >
> > I know that currently the documentation for highdicom is a little lacking . However there is a branch that I have been working on with a much improved user guide. The branch is called "seg_explanation" but also covers SR. I suggest you see whether the documentation on that branch may explain things better. Specifically these files (though it may be better to build the html docs yourself to make them readable in a browser as intended, see the developer guide for instrucitons to build the docs):
> >
> > General SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/generalsr.rst
> > Creating TID1500 SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/tid1500.rst
> >
> > Hope this helps. If you have more specific questions, I'm happy to try and answer.
> >
> > Best,
> > Chris

I can't speak to how viewers will render it, but it is certainly possible to include Measurement Groups defined using (2D) Image Coordinates into a Comprehensive3DSR document. You would just use a highdicom.sr.PlanarROIMeasurementsAndQualitativeEvaluations or highdicom.sr.VolumetricROIMeasurementsAndQualitativeEvaluations object (according to whether you are describing a 2D or 3D region) and pass either a single highdicom.sr.ImageRegion (for a planar group) or a list of highdicom.sr.ImageRegion objects (volumetric). It is confusing, but note that the dimensionality of the region itself (2D/planar or 3D/volumetric) is independent from the choice of coordinate system used to describe it (image coordinates (2D SCOORD ) vs frame-of-reference (3D, SCOORD3D)). Further ComprehensiveSR documents support only using only the Image Coordinate System, whereas Comprehensive3DSR documents support using the Image Coordinate System (2D) and/or the Frame of Reference Coordinate System (3D).

Re: DICOM SR Template Preparation

<d5f1a5ae-ac22-4ace-916b-ae3a2c7b19a5n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1432&group=comp.protocols.dicom#1432

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a05:622a:1f16:b0:3ab:c68a:de4f with SMTP id ca22-20020a05622a1f1600b003abc68ade4fmr670556qtb.511.1674539333698;
Mon, 23 Jan 2023 21:48:53 -0800 (PST)
X-Received: by 2002:a25:c6c7:0:b0:80b:52b3:6423 with SMTP id
k190-20020a25c6c7000000b0080b52b36423mr219038ybf.383.1674539333425; Mon, 23
Jan 2023 21:48:53 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 21:48:53 -0800 (PST)
In-Reply-To: <f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=78.187.44.157; posting-account=yx9n7QkAAACUcKfLGnjbEZV3PHuIQp03
NNTP-Posting-Host: 78.187.44.157
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <d5f1a5ae-ac22-4ace-916b-ae3a2c7b19a5n@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: agymtcelik11@gmail.com (Yusuf CELIK)
Injection-Date: Tue, 24 Jan 2023 05:48:53 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 5925
 by: Yusuf CELIK - Tue, 24 Jan 2023 05:48 UTC

23 Ocak 2023 Pazartesi tarihinde saat 16:25:15 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> As you know, for referencing an ROI that spans multiple slices, how to encode that using TID 1500 depends on whether you are referencing a SEG that defines the ROI as bit planes, or using contours within the SR itself defined inside TID 1411 Volumetric ROI Measurements and Qualitative Evaluations using 2D or 3D coordinates; it sounds like you are using the last of the three choices.
>
> If you are concerned about support for 3D coordinates and Comprehensive3DSR among recipients, then map the 3D coordinates to 2D image-relative coordinates yourself and send those instead. It may be that highdicom doesn't have a lot of support for 3D ROIs with 2D coordinates due to the preferences and priorities of some of its developers, but I am not sure.
>
> If highdicom s currently insufficient, then you can fork and fix it yourself since it is open source, or contact one of the developers and discuss it with them. That is probably easier than starting from scratch yourself. That said, what you are asking for sounds straightforward, and again, the highdicom developers may be able to help you if the documentation does not (yet) cover your use case.
>
> Creating a populated template from scratch, whether it be programmatically or declaratively in some sort of toolkit-specific JSON or XML, and then using dcmtk or PixelMed tools to convert the latter to DICOM binary encoding is quite painful, which is why tools like highdicom (and dcmqi before that) exist. We did try to "standardize" the declarative approach using JSON in Supplement 219 to make this easier, and it is available as a frozen draft (and implemented in my PixelMed toolkit), but it hasn't progressed to final text due to limited interest from the AI developer community and lack of other implementations. You are welcome to try it though (https://www.dclunie..com/dicom-status/status.html#supplement219).
>
> Whatever you do, make sure you validate your encoded results using both dciodvfy and DicomSRValidator from PixelMed.
>
> David
> On Monday, January 23, 2023 at 7:45:48 AM UTC-5, Yusuf CELIK wrote:
> > 23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> > > On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
> > >
> > > > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> > > Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
> > >
> > > https://link.springer.com/article/10.1007/s10278-022-00683-y
> > > https://github.com/ImagingDataCommons/highdicom
> > >
> > > David
> > Hi David
> >
> > On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.

Hello again,

First of all, thank you very much for the information you provided. As you said, at this stage, we set the 3D images as 2D in the code section and display them in the SR file. Likewise, since we mark the diseased areas on a pixel basis, we show the pixel values in 2D images and specify them in the SR file. This seems a little complicated, but it's the best we've got. It seems like it's getting harder and harder to do with the help of DCMTK.

Re: DICOM SR Template Preparation

<9f7458b3-6dc1-4ba4-a124-d75e20b113cbn@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1433&group=comp.protocols.dicom#1433

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:ae9:e70f:0:b0:709:1a1:e292 with SMTP id m15-20020ae9e70f000000b0070901a1e292mr629981qka.375.1674539427773;
Mon, 23 Jan 2023 21:50:27 -0800 (PST)
X-Received: by 2002:a81:4a8a:0:b0:4f8:e39f:6780 with SMTP id
x132-20020a814a8a000000b004f8e39f6780mr1861870ywa.68.1674539427491; Mon, 23
Jan 2023 21:50:27 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 21:50:27 -0800 (PST)
In-Reply-To: <6a82f778-1480-434e-9b2c-ebfeda5f27c2n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=78.187.44.157; posting-account=yx9n7QkAAACUcKfLGnjbEZV3PHuIQp03
NNTP-Posting-Host: 78.187.44.157
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com> <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
<0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com> <6a82f778-1480-434e-9b2c-ebfeda5f27c2n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <9f7458b3-6dc1-4ba4-a124-d75e20b113cbn@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: agymtcelik11@gmail.com (Yusuf CELIK)
Injection-Date: Tue, 24 Jan 2023 05:50:27 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 9429
 by: Yusuf CELIK - Tue, 24 Jan 2023 05:50 UTC

24 Ocak 2023 Salı tarihinde saat 04:29:41 UTC+3 itibarıyla Chris Bridge şunları yazdı:
> On Monday, 23 January 2023 at 09:34:05 UTC-5, sdo...@gmail.com wrote:
> > Hi Yusuf -
> >
> > Dave Clunie's suggestion of using 2D coordinates in a Comprehensive 3D TID 1500 does work - this is what I used in the RSNA IAIP showcase last November. The images can be displayed in both the Fovia viewer and in the OHIF v3 stable branch.
> >
> > Sean
> > On Monday, January 23, 2023 at 9:23:05 AM UTC-5, Chris Bridge wrote:
> > > On Monday, 23 January 2023 at 08:25:15 UTC-5, dcl...@dclunie.com wrote:
> > > > As you know, for referencing an ROI that spans multiple slices, how to encode that using TID 1500 depends on whether you are referencing a SEG that defines the ROI as bit planes, or using contours within the SR itself defined inside TID 1411 Volumetric ROI Measurements and Qualitative Evaluations using 2D or 3D coordinates; it sounds like you are using the last of the three choices.
> > > >
> > > > If you are concerned about support for 3D coordinates and Comprehensive3DSR among recipients, then map the 3D coordinates to 2D image-relative coordinates yourself and send those instead. It may be that highdicom doesn't have a lot of support for 3D ROIs with 2D coordinates due to the preferences and priorities of some of its developers, but I am not sure.
> > > >
> > > > If highdicom s currently insufficient, then you can fork and fix it yourself since it is open source, or contact one of the developers and discuss it with them. That is probably easier than starting from scratch yourself. That said, what you are asking for sounds straightforward, and again, the highdicom developers may be able to help you if the documentation does not (yet) cover your use case.
> > > >
> > > > Creating a populated template from scratch, whether it be programmatically or declaratively in some sort of toolkit-specific JSON or XML, and then using dcmtk or PixelMed tools to convert the latter to DICOM binary encoding is quite painful, which is why tools like highdicom (and dcmqi before that) exist. We did try to "standardize" the declarative approach using JSON in Supplement 219 to make this easier, and it is available as a frozen draft (and implemented in my PixelMed toolkit), but it hasn't progressed to final text due to limited interest from the AI developer community and lack of other implementations. You are welcome to try it though (https://www.dclunie.com/dicom-status/status.html#supplement219).
> > > >
> > > > Whatever you do, make sure you validate your encoded results using both dciodvfy and DicomSRValidator from PixelMed.
> > > >
> > > > David
> > > > On Monday, January 23, 2023 at 7:45:48 AM UTC-5, Yusuf CELIK wrote:
> > > > > 23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> > > > > > On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
> > > > > >
> > > > > > > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> > > > > > Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
> > > > > >
> > > > > > https://link.springer.com/article/10.1007/s10278-022-00683-y
> > > > > > https://github.com/ImagingDataCommons/highdicom
> > > > > >
> > > > > > David
> > > > > Hi David
> > > > >
> > > > > On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.
> > > Hi Yusuf,
> > >
> > > I am one of the developers of highdicom. I'm afraid that I don't understand what is currently missing in highdicom that you require. Almost all elements of TID 1500 are there in Python classes. What is this "Annex" that you are referring to?
> > >
> > > I know that currently the documentation for highdicom is a little lacking . However there is a branch that I have been working on with a much improved user guide. The branch is called "seg_explanation" but also covers SR. I suggest you see whether the documentation on that branch may explain things better. Specifically these files (though it may be better to build the html docs yourself to make them readable in a browser as intended, see the developer guide for instrucitons to build the docs):
> > >
> > > General SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/generalsr.rst
> > > Creating TID1500 SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/tid1500.rst
> > >
> > > Hope this helps. If you have more specific questions, I'm happy to try and answer.
> > >
> > > Best,
> > > Chris
> I can't speak to how viewers will render it, but it is certainly possible to include Measurement Groups defined using (2D) Image Coordinates into a Comprehensive3DSR document. You would just use a highdicom.sr.PlanarROIMeasurementsAndQualitativeEvaluations or highdicom.sr.VolumetricROIMeasurementsAndQualitativeEvaluations object (according to whether you are describing a 2D or 3D region) and pass either a single highdicom.sr.ImageRegion (for a planar group) or a list of highdicom.sr.ImageRegion objects (volumetric). It is confusing, but note that the dimensionality of the region itself (2D/planar or 3D/volumetric) is independent from the choice of coordinate system used to describe it (image coordinates (2D SCOORD ) vs frame-of-reference (3D, SCOORD3D)). Further ComprehensiveSR documents support only using only the Image Coordinate System, whereas Comprehensive3DSR documents support using the Image Coordinate System (2D) and/or the Frame of Reference Coordinate System (3D).

I will review the links you sent again. I've looked into it before, but maybe I missed something. Thank you. What Highdicom cannot do is this: If you are going to tag a certain number of slices in 3D images and you are going to run it through SR, highdicom has difficulties here. The challenge is this: Comprehensive3DSR is not working properly. There is no problem in creating the SR file, but it cannot view the generated SR file. It doesn't even show the images to be referenced most of the time. Other Annex on this matter. What we call Annex is this: It is the section where the diseased regions in the images defined in the SR file are shown and the coordinates are specified. For example, Annex 1 specifies the center point. Annex 2 specifies a polygon. The number of annexes increases over the fully segmented region.

Re: DICOM SR Template Preparation

<504373a9-3673-426e-997a-dc515ce50a0dn@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1434&group=comp.protocols.dicom#1434

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a05:6214:3483:b0:534:dfd1:419d with SMTP id mr3-20020a056214348300b00534dfd1419dmr1607360qvb.102.1674539461242;
Mon, 23 Jan 2023 21:51:01 -0800 (PST)
X-Received: by 2002:a81:4e85:0:b0:4f7:b1e:61e7 with SMTP id
c127-20020a814e85000000b004f70b1e61e7mr2396687ywb.172.1674539461013; Mon, 23
Jan 2023 21:51:01 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer02.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Mon, 23 Jan 2023 21:51:00 -0800 (PST)
In-Reply-To: <0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=78.187.44.157; posting-account=yx9n7QkAAACUcKfLGnjbEZV3PHuIQp03
NNTP-Posting-Host: 78.187.44.157
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com> <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
<0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <504373a9-3673-426e-997a-dc515ce50a0dn@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: agymtcelik11@gmail.com (Yusuf CELIK)
Injection-Date: Tue, 24 Jan 2023 05:51:01 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 7374
 by: Yusuf CELIK - Tue, 24 Jan 2023 05:51 UTC

23 Ocak 2023 Pazartesi tarihinde saat 17:34:05 UTC+3 itibarıyla sdo...@gmail.com şunları yazdı:
> Hi Yusuf -
>
> Dave Clunie's suggestion of using 2D coordinates in a Comprehensive 3D TID 1500 does work - this is what I used in the RSNA IAIP showcase last November. The images can be displayed in both the Fovia viewer and in the OHIF v3 stable branch.
>
> Sean
> On Monday, January 23, 2023 at 9:23:05 AM UTC-5, Chris Bridge wrote:
> > On Monday, 23 January 2023 at 08:25:15 UTC-5, dcl...@dclunie.com wrote:
> > > As you know, for referencing an ROI that spans multiple slices, how to encode that using TID 1500 depends on whether you are referencing a SEG that defines the ROI as bit planes, or using contours within the SR itself defined inside TID 1411 Volumetric ROI Measurements and Qualitative Evaluations using 2D or 3D coordinates; it sounds like you are using the last of the three choices.
> > >
> > > If you are concerned about support for 3D coordinates and Comprehensive3DSR among recipients, then map the 3D coordinates to 2D image-relative coordinates yourself and send those instead. It may be that highdicom doesn't have a lot of support for 3D ROIs with 2D coordinates due to the preferences and priorities of some of its developers, but I am not sure.
> > >
> > > If highdicom s currently insufficient, then you can fork and fix it yourself since it is open source, or contact one of the developers and discuss it with them. That is probably easier than starting from scratch yourself. That said, what you are asking for sounds straightforward, and again, the highdicom developers may be able to help you if the documentation does not (yet) cover your use case.
> > >
> > > Creating a populated template from scratch, whether it be programmatically or declaratively in some sort of toolkit-specific JSON or XML, and then using dcmtk or PixelMed tools to convert the latter to DICOM binary encoding is quite painful, which is why tools like highdicom (and dcmqi before that) exist. We did try to "standardize" the declarative approach using JSON in Supplement 219 to make this easier, and it is available as a frozen draft (and implemented in my PixelMed toolkit), but it hasn't progressed to final text due to limited interest from the AI developer community and lack of other implementations. You are welcome to try it though (https://www.dclunie.com/dicom-status/status.html#supplement219).
> > >
> > > Whatever you do, make sure you validate your encoded results using both dciodvfy and DicomSRValidator from PixelMed.
> > >
> > > David
> > > On Monday, January 23, 2023 at 7:45:48 AM UTC-5, Yusuf CELIK wrote:
> > > > 23 Ocak 2023 Pazartesi tarihinde saat 15:38:25 UTC+3 itibarıyla dcl...@dclunie.com şunları yazdı:
> > > > > On Monday, January 23, 2023 at 12:10:31 AM UTC-5, Yusuf CELIK wrote:
> > > > >
> > > > > > I want to prepare an SR file to use in an AI project. I want to advance on TID 1500 template. I have completed my research, but there is only one question in my mind. Does each person dealing with these things have to create their own SR template from scratch? I will do this work using the Python. Should I prepare a custom SR template for my own project from scratch with the Python following all the rules of the TID 1500 template or is there an easier way?
> > > > > Since you are a Python user, there is an easier way using the highdicom tool, since it specifically addresses using SR TID 1500 for your sort of use case, such as encoding of annotations of entire images, planar image regions, or volumetric image regions:
> > > > >
> > > > > https://link.springer.com/article/10.1007/s10278-022-00683-y
> > > > > https://github.com/ImagingDataCommons/highdicom
> > > > >
> > > > > David
> > > > Hi David
> > > >
> > > > On the Highdicom side, my requests are not fully met. Since I work with 3D images, the Comprehensive3DSR and ImageRegion3D functions on the highdicom side may cause difficulties in viewing the SR file. When I need to mark more than one slice, I cannot define Annex as necessary. Yes, there is a template, but there is no software (code-wise) example of it. I understand that many people do this with DCMTK, but in order to use that library, I guess you need to create your own template from scratch. This is another difficult way. But thank you very much for your comment.
> > Hi Yusuf,
> >
> > I am one of the developers of highdicom. I'm afraid that I don't understand what is currently missing in highdicom that you require. Almost all elements of TID 1500 are there in Python classes. What is this "Annex" that you are referring to?
> >
> > I know that currently the documentation for highdicom is a little lacking . However there is a branch that I have been working on with a much improved user guide. The branch is called "seg_explanation" but also covers SR. I suggest you see whether the documentation on that branch may explain things better. Specifically these files (though it may be better to build the html docs yourself to make them readable in a browser as intended, see the developer guide for instrucitons to build the docs):
> >
> > General SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/generalsr.rst
> > Creating TID1500 SRs: https://github.com/ImagingDataCommons/highdicom/blob/docs/seg_explanation/docs/tid1500.rst
> >
> > Hope this helps. If you have more specific questions, I'm happy to try and answer.
> >
> > Best,
> > Chris

I'll look into it by working on it more. Thanks.

Re: DICOM SR Template Preparation

<cb8dd048-1e05-415f-9bbe-1c0c686d7958n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=1435&group=comp.protocols.dicom#1435

  copy link   Newsgroups: comp.protocols.dicom
X-Received: by 2002:a05:6214:16c8:b0:539:39e8:2238 with SMTP id d8-20020a05621416c800b0053939e82238mr35621qvz.92.1674815373555;
Fri, 27 Jan 2023 02:29:33 -0800 (PST)
X-Received: by 2002:a0d:eb0b:0:b0:506:5637:b000 with SMTP id
u11-20020a0deb0b000000b005065637b000mr1353917ywe.461.1674815373307; Fri, 27
Jan 2023 02:29:33 -0800 (PST)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!feed1.usenet.blueworldhosting.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.protocols.dicom
Date: Fri, 27 Jan 2023 02:29:33 -0800 (PST)
In-Reply-To: <504373a9-3673-426e-997a-dc515ce50a0dn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=85.16.189.49; posting-account=P9OsJAoAAABf_UoLgO-4Y0jtck08GqVx
NNTP-Posting-Host: 85.16.189.49
References: <4b32e16f-cd44-4723-87aa-6918f5c6a12an@googlegroups.com>
<41b23f34-4b2e-4fe1-ba01-820d02c669can@googlegroups.com> <f5028355-79af-43e8-8b50-9d9843fd8ea5n@googlegroups.com>
<f9ac6237-cc67-4ba4-8a4b-44cb01edec31n@googlegroups.com> <193d0c7c-371a-46db-9b6e-4557c313da87n@googlegroups.com>
<0c63b0df-5602-4755-8c3f-165d8f0b018en@googlegroups.com> <504373a9-3673-426e-997a-dc515ce50a0dn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <cb8dd048-1e05-415f-9bbe-1c0c686d7958n@googlegroups.com>
Subject: Re: DICOM SR Template Preparation
From: dicom@jriesmeier.com (Jörg Riesmeier)
Injection-Date: Fri, 27 Jan 2023 10:29:33 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
X-Received-Bytes: 2165
 by: Jörg Riesmeier - Fri, 27 Jan 2023 10:29 UTC

Since DCMTK was mentioned, I just wanted to refer to the high-level TID 1500 implementation that is also part of the DCMTK: https://support.dcmtk.org/docs/classTID1500__MeasurementReport.html

Being the author of DCMTK's SR implementation and also of this particular class (and associated classes), I know of course that it does not support all optional features of the rather flexible TID 1500 structure. However, it might be a good starting point for what you intend to do. And, we are always happy to get code contribution, so please feel free to extend the classes as needed.

Regards,
Jörg

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor