DCM4CHEE如何存储DICOM图像的位分配信息

发布于 2024-09-27 03:16:02 字数 252 浏览 2 评论 0原文

我们使用 DCM4CHEE 作为 PACS 服务器的副本。我有 8 位和 16 位图像分布在多项研究中。所有图像都存储在 DCM4CHEE 中。

我们在示例图像上运行 DICOM DUMP [DCM2TXT] 来识别位分配。这是一个漫长的过程。

DCM4CHEE 服务器是否将位表示存储在数据库中?如果是,我在哪里可以找到有关分配的位的信息?

请帮助我找到最佳解决方案。

谢谢,

-Anil Kumar.C

We are using DCM4CHEE as replica of PACS server. I have 8 bit and 16 bit images spread across multiple studies. All the images are stored in DCM4CHEE.

We are running DICOM DUMP [DCM2TXT] on sample images to identify the bits allocation. It is a lengthy process.

Does DCM4CHEE server stores the bits representation in DB?, if so where can I find the information about the bits allocated?

Please help me in finding the best solution for this.

Thanks,

-Anil Kumar.C

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

心是晴朗的。 2024-10-04 03:16:02

是的,它在数据库中并且可以非常快地访问。在数据库/架构“pacsdb”中,表名称为“instance”,列名称为“inst_attrs”。最有可能的是,您必须对涉及研究和系列表的联接进行选择,具体取决于您搜索/呈现数据的方式。

现在的问题是,inst_attrs 是一个具有二进制数据的 BLOB。在内部,您需要查找以下十六进制字符串(来自 DICOM 传输语法)28 00 00 01 55 53 02 00 xx 00
这里,28 00 00 01实际上是十六进制的(0028, 0100)标签(分配的位),55 53 02 00表示“无符号短(US)2字节长”,之后通常是10 00表示16位或08 00 表示 8 位图像。因此,您实际上只需要上面字节中的“xx”值。

根据您将用于获取此数据的数据库访问工具,您可以选择最佳策略。它可以是与 dcm4chee 一起部署的 Web 应用程序 (.war),可能只需一堆 jsp 就足够了;它可以是一个单独的 Java 应用程序,甚至是 .NET - 选择的工具实际上取决于您需要它的位置和用途。对于 Web 访问,我宁愿使用无状态会话 bean 来执行完整的 .ear 来获取数据,并使用受密码保护的小型 Web 应用程序来呈现数据并提供来自外部的 JSON / WS 访问。

更新
下面是一个 SQL 示例(仅限 MySQL),它返回研究 UID、系列 UID 以及分配为 10(对于 16 位图像)和 08(对于 8 位图像)的位:

SELECT study_iuid as StudyUID, series_iuid as SeriesUID,
    SUBSTRING(HEX(inst_attrs),
               LOCATE('2800000155530200',HEX(inst_attrs))+16
             ,2) as BitsAllocatedHex 
    FROM instance i JOIN series s ON i.series_fk=s.pk 
        JOIN study st ON s.study_fk=st.pk

Yes, it is in the database and can be accessed very fast. In the database/schema 'pacsdb' the table name is 'instance', the column name is 'inst_attrs'. Most probably you will have to make a select with joins involving study and series tables, depending on how you search/present your data.

Now, the problem is, inst_attrs is a BLOB with binary data. Inside, you would need to look for the following hex string (from DICOM transfer syntax) 28 00 00 01 55 53 02 00 xx 00
Here, 28 00 00 01 is actually hex for (0028, 0100) tag (Bits Allocated), 55 53 02 00 says "Unsigned Short (US) 2 bytes long", and after that there is usually 10 00 for 16 bit or 08 00 for 8 bit images. So, you really only need the "xx" value from the bytes above.

Depending on the database access tools you will be using to get this data, you can choose the best strategy. It can be a web app (.war) deployed along side with dcm4chee, probably just a bunch of jsp's will be enough; it can be a separate java app or even .NET - the tool of choice really depends on where and for what do you need it. For web access I would rather do a full .ear with stateless session bean to fetch the data and small, password-protected web app to present the data and provide JSON / WS access from the outside.

Update
Below is an SQL example (MySQL only) that returns study UID, series UID and bits allocated as 10 for 16-bit and 08 for 8-bit images:

SELECT study_iuid as StudyUID, series_iuid as SeriesUID,
    SUBSTRING(HEX(inst_attrs),
               LOCATE('2800000155530200',HEX(inst_attrs))+16
             ,2) as BitsAllocatedHex 
    FROM instance i JOIN series s ON i.series_fk=s.pk 
        JOIN study st ON s.study_fk=st.pk

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文