Showing posts with label GDCM. Show all posts
Showing posts with label GDCM. Show all posts

Monday, December 17, 2012

gdcm and submodule gdcmData


During migration, the tool simply copy/pasted the old submodule URL, which lead to inconsistencies such:

$ git clone --recursive git://git.code.sf.net/p/gdcm/gdcm
Cloning into 'gdcm'...
remote: Counting objects: 65664, done.
remote: Compressing objects: 100% (13537/13537), done.
remote: Total 65664 (delta 51934), reused 65658 (delta 51930)
Receiving objects: 100% (65664/65664), 20.31 MiB | 2.32 MiB/s, done.
Resolving deltas: 100% (51934/51934), done.
Submodule 'Testing/Data' (git://gdcm.git.sourceforge.net/gitroot/gdcm/gdcmData) registered for path 'Testing/Data'
Cloning into 'Testing/Data'...
remote: Counting objects: 438, done.
remote: Compressing objects: 100% (303/303), done.
remote: Total 438 (delta 134), reused 428 (delta 131)
Receiving objects: 100% (438/438), 160.33 MiB | 7.25 MiB/s, done.
Resolving deltas: 100% (134/134), done.
Submodule path 'Testing/Data': checked out 'ebd3260d5dd315dd99dae78c783c2fc1beb18f01'
Well, this is not really an issue, we will just delete the old submodule and point to the new one.

Seems easy ? Well not quite, the new Allura does not cope with Upper case in name for mount point, so gdcmData needs to be gdcmdata now ...

Update: the following page explains how to delete (rm) submodule:
http://chrisjean.com/2009/04/20/git-submodules-adding-using-removing-and-updating/

GDCM Git migration in sf.net

Migration of GDCM to new sf.net/allura system did not work quite as I expected. I really like the shell based control I used to have.

So here is what I discover to copy/over the old setup to the new one:

Login to your shell space:
$ ssh -t malat,gdcm@shell.sf.net create
As 17/12/2012, the sf-help command is not really helpful since it only returns path to my old git directory:

% sf-help
[...]
Your project DSCM repositories are here (use adminrepo for CVS and SVN):
/home/scm_git/g/gd/gdcm

Anyway I discover this is right here:

$ cd /home/git/p/gdcm
The new system is not as flexible, you cannot easily create new directory:

[malat@shell-22006]/home/git/p/gdcm% touch bla.git
touch: cannot touch `bla.git': Permission denied
Instead you have to go back to the web interface, go 'Admin', then 'Tools', then click 'Git'. It will ask for a Label and a Mount Point, in my case I wanted Code/code to become Gdcm/gdcm. Fill accordingly to your project. Click ok.

Now if you go back to

$ cd /home/git/p/gdcm
You'll be pleasantly surprised... that nothing happened. Even if you log off, and log back in, no gdcm.git has been created...well technically yes. Simply type:

[malat@shell-22006]/home/git/p/gdcm% shutdown
and then log back in:

$ ssh -t malat,gdcm@shell.sf.net create
$ cd /home/git/p/gdcm
And now, you can edit in place file as you want

[malat@shell-22006]/home/git/p/gdcm% echo "super" > gdcm.git/description 
Now all is left to do is copy code.git over to gdcm.git:

$ git clone --mirror git://git.code.sf.net/p/gdcm/code
$ cd code.git
$ git push --mirror --all ssh://malat@git.code.sf.net/p/gdcm/gdcm
You can even use diff to your old rep:

[malat@shell-22006]/home/git/p/gdcm% diff -ru gdcm.git /home/scm_git/g/gd/gdcm/gdcm
Of course, when you are done, go back to Allura web interface, go to Admin/Tools and select select Git/Code and click 'Delete'.
Hope this help !

Update: Only after struggling with this did I discover the path was actually documented here:

https://sourceforge.net/p/forge/documentation/Git/#accessing-the-repository-via-the-shell

Tuesday, November 20, 2012

Migrating GDCM wiki

I am following instructions from sf.net admins to move gdcm wiki to new platform, however it failed with:
ref:
https://sourceforge.net/p/forge/community-docs/Migrating%20MediaWiki%20from%20Hosted%20Apps/

Sunday, September 16, 2012

Un cancéreux pirate son dossier médical pour demander l’aide du Web

On parle de DICOM dans un site grand public [1]. Le titre est très accrocheur:
Un cancéreux pirate son dossier médical pour demander l’aide du Web
Après des années de travail sur GDCM (Grassroots DICOM), après avoir fait du reverse engineering sur des modes de compression privés utilisés par certains vendeurs et référencés sur le fameux "hall of shame" [2]. Je me suis dit "wow", j'ai peut-être trouvé la solution au dernier codec non-supporté dans GDCM, le fameux LOSSLESS ELSCINCT que je n'ai jamais pu utiliser !

Je continue donc l'article, qui devient de plus en plus intéressant:
Il décide donc de le « craquer » et de le publier sur son site pour demander de l'aide aux internautes.
Ça y est, on parle de crackage, c'est même plus un gentil hacker, Laconesi est carrément un crackeur ! Le héros des temps moderne, le John Draper des compressions d'images !

La suite de l'article devient beaucoup moins drôle, on parle de "format fermé et propriétaire", et un peu plus loin de "Dicom", j'imagine que l'auteur voulait parler de "DICOM", jusqu'à ce que l'académie française accepte le mot (radar, laser...), ça reste un acronyme, donc en majuscule.

La suite est encore pire "difficilement accessible". C'est là que j'ai arrêté la lecture et j'ai téléchargé ses données:
Je regarde le premier tarball:

$ gdcminfo TAC_CD_20120827_130200/DICOM/00000000 MediaStorage is 1.2.840.10008.5.1.4.1.1.2 [CT Image Storage]
TransferSyntax is 1.2.840.10008.1.2.4.90 [JPEG 2000 Image Compression (Lossless Only)]
[...]


Alors là je comprends ce qu'il s'est passé. Laconesi a pris la première implémentation DICOM qu'il a trouvée sur sf.net et/ou code.google.com et évidement le codec JP2 n'était pas disponible...d'où sa démarche. Pour le coup JP2 est une norme ISO dont l'accès à la norme est payant, alors que DICOM n'est pas une norme ISO et l'accès au standard (fichiers PDFs) est complètement et entièrement gratuit.

Je rejoins l'article dans le sens où il y a beaucoup d’implémentations DICOM, mais elles ne sont pas toutes équivalentes. Mais c'est un autre débat, et des groupes comme debian-med ont par exemple rassemblé sous une seule organisation les meilleurs softs open-source pour le domaine médical, dans notre cas le sous-groupe debian-med est celui-ci:
On y retrouve quelques implémentations DICOM, dont GDCM qui elle implémente le codec JP2. Le problème est que plusieurs d'entres elles ne le supportent pas du tout. Ou alors le supportent mais utilisent Jasper (une implémentation JP2 invalide pour DICOM), comme expliqué lors de ma présentation à RMLL/2011 (et 2012 d'ailleurs):
Le titre de l'article est très accrocheur mais, à mon sens, il rate vraiment le principal :
  1. meilleur support de JPEG 2000 dans le monde opensource (vous pouvez me rejoindre @openjpeg)
  2. interface simplifiée pour relire les images (ginkgocadx est bien dans cette approche mais utilise DCMTK pour lire les fichiers DICOM, et DCMTK a décidé de ne pas distribuer gratuitement son module JPEG 2000 [3].
Sinon la fin de l'article évoque un problème intéressant: l’accès à des images numériques médicales. Là je suis entièrement d'accord avec l'auteur, cela devrait être simplifié. Mais comme l’Europe et l’Amérique du Nord ont des conditions très dures pour la diffusion des informations patient (Protected Health Information[4]), le plus simple c'est de ne pas diffuser du tout les informations patient.

Ce côté me rassure, car je ne serais pas du tout heureux d’apprendre que mon dossier médical traîne sur des réseaux sociaux. C'est pour cela que la démarche émane forcement du patient lui-même, et j'invite donc notre "apprenti craqueur" à transmettre ses données directement à Patient Contributed Image Repository (PCIR) [5] de façon à contribuer à une meilleure connaissance de DICOM par le grand public.

Si vous êtes arrivés jusque-là, merci de votre lecture et comme je le dis souvent, ramenez vos CD (écho, radio, IRM...) à votre domicile et vérifiez par vous-même que vous avez accès à vos propres données via un soft open source !

Thursday, March 31, 2011

Unhandled exception: page fault on read access to 0x00342000 in 32-bit code (0x00560b16).

wine has made some fantastic progress. I can configure/build GDCM now. Some options needs to be turned off for now:




Unhandled exception: page fault on read access to 0x00342000 in 32-bit code (0x00560b16).
Register dump:
CS:0023 SS:002b DS:002b ES:002b FS:0063 GS:006b
EIP:00560b16 ESP:0100e390 EBP:ffffffff EFLAGS:00010297( R- -- I S -A-P-C)
EAX:0000a1a5 EBX:00319938 ECX:00319968 EDX:00007d53
ESI:010cd300 EDI:00000000
Stack dump:
0x0100e390: 0100e3cc 0100e3dc 010cd300 00000000
0x0100e3a0: 00561e29 ffffffff 00000000 00000010
0x0100e3b0: 010cd300 00000018 00000000 00000000
0x0100e3c0: 00000000 00000004 00000000 ff676980
0x0100e3d0: ffffffff d316536e 01cbefa1 00000004
0x0100e3e0: 00000000 004d35b1 010cd300 0100e43c
Backtrace:
0x00560b16: movl 0x4(%ecx,%eax,4),%edx
Modules:
Module Address Debug info Name (60 modules)
PE 400000- 67e000 Export cmake
PE 78480000-7850d000 Deferred msvcp90
PE 78520000-785c3000 Deferred msvcr90
ELF 7b800000-7b8e6000 Deferred kernel32
\-PE 7b810000-7b8e6000 \ kernel32
ELF 7bc00000-7bcbb000 Deferred ntdll
\-PE 7bc10000-7bcbb000 \ ntdll
ELF 7bf00000-7bf03000 Deferred
ELF 7e589000-7e5a7000 Deferred libgcc_s.so.1
ELF 7e5a7000-7e5b0000 Deferred libxcursor.so.1
ELF 7e5b0000-7e5b5000 Deferred libxfixes.so.3
ELF 7e5b5000-7e5b8000 Deferred libxcomposite.so.1
ELF 7e5b8000-7e5bf000 Deferred libxrandr.so.2
ELF 7e5bf000-7e5c8000 Deferred libxrender.so.1
ELF 7e5c8000-7e5cd000 Deferred libxxf86vm.so.1
ELF 7e5cd000-7e5d0000 Deferred libxinerama.so.1
ELF 7e5d0000-7e5f0000 Deferred imm32
\-PE 7e5e0000-7e5f0000 \ imm32
ELF 7e5f0000-7e5f5000 Deferred libxdmcp.so.6
ELF 7e5f5000-7e60e000 Deferred libxcb.so.1
ELF 7e60e000-7e72b000 Deferred libx11.so.6
ELF 7e72b000-7e73a000 Deferred libxext.so.6
ELF 7e73a000-7e751000 Deferred libice.so.6
ELF 7e751000-7e759000 Deferred libsm.so.6
ELF 7e77e000-7e827000 Deferred winex11
\-PE 7e790000-7e827000 \ winex11
ELF 7e83d000-7e863000 Deferred libexpat.so.1
ELF 7e863000-7e892000 Deferred libfontconfig.so.1
ELF 7e892000-7e8a6000 Deferred libz.so.1
ELF 7e8a6000-7e91d000 Deferred libfreetype.so.6
ELF 7e942000-7ea2e000 Deferred oleaut32
\-PE 7e960000-7ea2e000 \ oleaut32
ELF 7ea2e000-7eb31000 Deferred ole32
\-PE 7ea50000-7eb31000 \ ole32
ELF 7eb31000-7eba5000 Deferred rpcrt4
\-PE 7eb40000-7eba5000 \ rpcrt4
ELF 7eba5000-7ec00000 Deferred advapi32
\-PE 7ebb0000-7ec00000 \ advapi32
ELF 7ec00000-7ec8e000 Deferred gdi32
\-PE 7ec10000-7ec8e000 \ gdi32
ELF 7ec8e000-7edbd000 Deferred user32
\-PE 7eca0000-7edbd000 \ user32
ELF 7edbd000-7edfa000 Deferred winmm
\-PE 7edd0000-7edfa000 \ winmm
ELF 7edfa000-7ee28000 Deferred ws2_32
\-PE 7ee00000-7ee28000 \ ws2_32
ELF 7ee28000-7ee3f000 Deferred libnsl.so.1
ELF 7efb5000-7efdb000 Deferred libm.so.6
ELF 7efdd000-7efe1000 Deferred libuuid.so.1
ELF 7efe8000-7f000000 Deferred version
\-PE 7eff0000-7f000000 \ version
ELF f7450000-f745c000 Deferred libnss_files.so.2
ELF f745d000-f7461000 Deferred libdl.so.2
ELF f7461000-f75a8000 Deferred libc.so.6
ELF f75a9000-f75c2000 Deferred libpthread.so.0
ELF f75c2000-f7703000 Deferred libwine-unstable.so.1
ELF f7703000-f7706000 Deferred libxau.so.6
ELF f7706000-f7710000 Deferred libnss_nis.so.2
ELF f7720000-f7728000 Deferred libnss_compat.so.2
ELF f772a000-f7748000 Deferred ld-linux.so.2
Threads:
process tid prio (all id:s are in hex)
0000000e services.exe
0000001c 0
00000014 0
00000010 0
0000000f 0
00000011 winedevice.exe
00000017 0
00000013 0
00000012 0
00000019 plugplay.exe
0000001d 0
0000001b 0
0000001a 0
0000001e explorer.exe
0000001f 0
00000036 mspdbsrv.exe
00000023 0
00000022 0
0000002b hh.exe
00000037 0
00000035 wineconsole.exe
0000002e 0
00000045 cmd.exe
00000038 0
0000003b (D) C:\Program Files\CMake 2.8\bin\cmake.exe
00000028 0
00000009 0
00000040 0
00000041 0
00000031 0 <== Backtrace:

Saturday, March 19, 2011

GDCM accepted as GSoC mentoring organization !

I have the immense pleasure to tell you that GDCM has been accepted as one of the 175 organizations participating in GSoC 2011:

http://www.google-melange.com/gsoc/program/accepted_orgs/google/gsoc2011

I will send out more details in the next few days, but this is
definitely a fantastic news. I would like to thank everyone of you who
participated with ideas and suggestions.

Monday, March 7, 2011

GDCM Goes GSoc !

An application for GDCM has been submitted to GSoc 2011 !

Here is the list of current proposals:
GDCM Summer of Code 2011


Read the announcement:

Mentoring Organization Applications Now Being Accepted for Google Summer of Code! - Google Open Source Blog

Wednesday, September 15, 2010

svn-all-fast-export

svn-all-fast-export --identity-map ../authors.txt --rules ../config /home/mathieu/tmp/git/svneverever/gdcm


$ git branch -a ~/tmp/git/svneverever/dummy/gdcm
gdcm-2-0
gdcm-2-0-10
gdcm-2-0-11
gdcm-2-0-12
gdcm-2-0-13
gdcm-2-0-14
gdcm-2-0-15
gdcm-2-0-16
* master

* http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=596937

svn2git

/var/lib/gems/1.8/bin/svn2git http://gdcm.svn.sourceforge.net/svnroot/gdcm/ --exclude Sandbox --exclude documentation

$ git tag -l ~/tmp/git/migrate
gdcm-2-0-10
gdcm-2-0-11
gdcm-2-0-12
gdcm-2-0-13
gdcm-2-0-14
gdcm-2-0-15
gdcm-2-0-16
gdcm-2-0-4
gdcm-2-0-5
gdcm-2-0-6
gdcm-2-0-7
gdcm-2-0-8
gdcm-2-0-9

$ git branch -a ~/tmp/git/migrate
gdcm-2-0
* master
trunk@1097
remotes/gdcm-2-0
remotes/trunk
remotes/trunk@1097

Friday, August 27, 2010

integration-gdcm-2-0-16 pushed to master !

This is a big day today ! GDCM 2.x has been pushed to ITK, enjoy !

$ ssh git@itk.org stage ITK merge integration-gdcm-2-0-16
Fetching upstream master
Merge topic 'integration-gdcm-2-0-16'

448bcde Rename GDCMTargets to ITKTargets
5714c2f Handle case where zlib is the system one
b25d59f Make sure to include a C99 wrapper for MSVC compiler
92d15f9 trivial compilation fixes
4c73133 Make sure to use proper name mangling
4be1690 remove openjpeg version for now
3891f5f Need to define openjpeg version major
f2b6ec7 Need to export libs
8284318 updates so that things configure in cmake 2.8 on windows
b322034 Fix GDCM to handle older expat library.
0949e16 Final pass to make GDCM compile within ITK
99893f1 Remove any reference to GDCM 1.x, update to GDCM 2.x
f08de4d Backport cmakelist from previous ITK version
fdb6b18 Update JPEG library (IJG 8b release)
0f12009 Adding a patched GDCM 2.0.16 version
b5848c3 Remove old unsupported GDCM 1.2.x source

Removing Utilities/gdcm/.cvsignore
Removing Utilities/gdcm/CMake/gdcmTestFUNCTION.cxx
Removing Utilities/gdcm/ChangeLog
Removing Utilities/gdcm/DEVELOPPER
Removing Utilities/gdcm/Dicts/.cvsignore
Removing Utilities/gdcm/Dicts/ACUSON.dic
Removing Utilities/gdcm/Dicts/CMakeLists.txt
Removing Utilities/gdcm/Dicts/DicomDir.dic
Removing Utilities/gdcm/Dicts/DictGroupName.dic
Removing Utilities/gdcm/Dicts/ELSCINT.dic
Removing Utilities/gdcm/Dicts/GE-EchoPAC.dic
Removing Utilities/gdcm/Dicts/GEMS-Advance.dic
Removing Utilities/gdcm/Dicts/GEMS-Advantx.dic
Removing Utilities/gdcm/Dicts/GEMS-CR.dic
Removing Utilities/gdcm/Dicts/GEMS-DLX.dic
Removing Utilities/gdcm/Dicts/GEMS-Genie.dic
Removing Utilities/gdcm/Dicts/GEMS-HiSpeed.dic
Removing Utilities/gdcm/Dicts/GEMS-Infinia.dic
Removing Utilities/gdcm/Dicts/GEMS.dic
Removing Utilities/gdcm/Dicts/HITACHI-MR-pronto.dic
Removing Utilities/gdcm/Dicts/PHILIPS-EasyVision.dic
Removing Utilities/gdcm/Dicts/PHILIPS-Intera.dic
Removing Utilities/gdcm/Dicts/Papyrus.dic
Removing Utilities/gdcm/Dicts/ParseDict.py
Removing Utilities/gdcm/Dicts/README
Removing Utilities/gdcm/Dicts/SIEMENS-syngo.dic
Removing Utilities/gdcm/Dicts/SIEMENS.dic
Removing Utilities/gdcm/Dicts/SPI.dic
Removing Utilities/gdcm/Dicts/dicomAttributeTypes.dic
Removing Utilities/gdcm/Dicts/dicomGroupNameAbbreviations.dic
Removing Utilities/gdcm/Dicts/dicomTS.dic
Removing Utilities/gdcm/Dicts/dicomV3PhilipsIntera.dic
Removing Utilities/gdcm/Dicts/dicomVR.dic
Removing Utilities/gdcm/Dicts/gdcm.dic.in
Removing Utilities/gdcm/INSTALL
Removing Utilities/gdcm/README
Removing Utilities/gdcm/README.ITK.txt
Removing Utilities/gdcm/gdcm.spec.in
Removing Utilities/gdcm/gdcmConfigure.h.in
Removing Utilities/gdcm/src/.cvsignore
Removing Utilities/gdcm/src/CMakeLists.txt
Removing Utilities/gdcm/src/gdcm.h
Removing Utilities/gdcm/src/gdcmArgMgr.cxx
Removing Utilities/gdcm/src/gdcmArgMgr.h
Removing Utilities/gdcm/src/gdcmBase.cxx
Removing Utilities/gdcm/src/gdcmBase.h
Removing Utilities/gdcm/src/gdcmBinEntry.cxx
Removing Utilities/gdcm/src/gdcmBinEntry.h
Removing Utilities/gdcm/src/gdcmCommon.h
Removing Utilities/gdcm/src/gdcmContentEntry.cxx
Removing Utilities/gdcm/src/gdcmContentEntry.h
Removing Utilities/gdcm/src/gdcmDebug.cxx
Removing Utilities/gdcm/src/gdcmDebug.h
Removing Utilities/gdcm/src/gdcmDefaultDicts.cxx.in
Removing Utilities/gdcm/src/gdcmDicomDir.cxx
Removing Utilities/gdcm/src/gdcmDicomDir.h
Removing Utilities/gdcm/src/gdcmDicomDirElement.cxx
Removing Utilities/gdcm/src/gdcmDicomDirElement.h
Removing Utilities/gdcm/src/gdcmDicomDirImage.cxx
Removing Utilities/gdcm/src/gdcmDicomDirImage.h
Removing Utilities/gdcm/src/gdcmDicomDirMeta.cxx
Removing Utilities/gdcm/src/gdcmDicomDirMeta.h
Removing Utilities/gdcm/src/gdcmDicomDirObject.cxx
Removing Utilities/gdcm/src/gdcmDicomDirObject.h
Removing Utilities/gdcm/src/gdcmDicomDirPatient.cxx
Removing Utilities/gdcm/src/gdcmDicomDirPatient.h
Removing Utilities/gdcm/src/gdcmDicomDirSerie.cxx
Removing Utilities/gdcm/src/gdcmDicomDirSerie.h
Removing Utilities/gdcm/src/gdcmDicomDirStudy.cxx
Removing Utilities/gdcm/src/gdcmDicomDirStudy.h
Removing Utilities/gdcm/src/gdcmDicomDirVisit.cxx
Removing Utilities/gdcm/src/gdcmDicomDirVisit.h
Removing Utilities/gdcm/src/gdcmDict.cxx
Removing Utilities/gdcm/src/gdcmDict.h
Removing Utilities/gdcm/src/gdcmDictEntry.cxx
Removing Utilities/gdcm/src/gdcmDictEntry.h
Removing Utilities/gdcm/src/gdcmDictGroupName.cxx
Removing Utilities/gdcm/src/gdcmDictGroupName.h
Removing Utilities/gdcm/src/gdcmDictSet.cxx
Removing Utilities/gdcm/src/gdcmDictSet.h
Removing Utilities/gdcm/src/gdcmDirList.cxx
Removing Utilities/gdcm/src/gdcmDirList.h
Removing Utilities/gdcm/src/gdcmDocEntry.cxx
Removing Utilities/gdcm/src/gdcmDocEntry.h
Removing Utilities/gdcm/src/gdcmDocEntryArchive.cxx
Removing Utilities/gdcm/src/gdcmDocEntryArchive.h
Removing Utilities/gdcm/src/gdcmDocEntrySet.cxx
Removing Utilities/gdcm/src/gdcmDocEntrySet.h
Removing Utilities/gdcm/src/gdcmDocument.cxx
Removing Utilities/gdcm/src/gdcmDocument.h
Removing Utilities/gdcm/src/gdcmElementSet.cxx
Removing Utilities/gdcm/src/gdcmElementSet.h
Removing Utilities/gdcm/src/gdcmException.cxx
Removing Utilities/gdcm/src/gdcmException.h
Removing Utilities/gdcm/src/gdcmFile.cxx
Removing Utilities/gdcm/src/gdcmFile.h
Removing Utilities/gdcm/src/gdcmFileHelper.cxx
Removing Utilities/gdcm/src/gdcmFileHelper.h
Removing Utilities/gdcm/src/gdcmGlobal.cxx
Removing Utilities/gdcm/src/gdcmGlobal.h
Removing Utilities/gdcm/src/gdcmJPEGFragment.cxx
Removing Utilities/gdcm/src/gdcmJPEGFragment.h
Removing Utilities/gdcm/src/gdcmJPEGFragmentsInfo.cxx
Removing Utilities/gdcm/src/gdcmJPEGFragmentsInfo.h
Removing Utilities/gdcm/src/gdcmJpeg.cxx
Removing Utilities/gdcm/src/gdcmJpeg12.cxx
Removing Utilities/gdcm/src/gdcmJpeg16.cxx
Removing Utilities/gdcm/src/gdcmJpeg2000.cxx
Removing Utilities/gdcm/src/gdcmJpeg8.cxx
Removing Utilities/gdcm/src/gdcmJpegLS.cxx
Removing Utilities/gdcm/src/gdcmMpeg.cxx
Removing Utilities/gdcm/src/gdcmOrientation.cxx
Removing Utilities/gdcm/src/gdcmOrientation.h
Removing Utilities/gdcm/src/gdcmPixelReadConvert.cxx
Removing Utilities/gdcm/src/gdcmPixelReadConvert.h
Removing Utilities/gdcm/src/gdcmPixelWriteConvert.cxx
Removing Utilities/gdcm/src/gdcmPixelWriteConvert.h
Removing Utilities/gdcm/src/gdcmRLEFrame.cxx
Removing Utilities/gdcm/src/gdcmRLEFrame.h
Removing Utilities/gdcm/src/gdcmRLEFramesInfo.cxx
Removing Utilities/gdcm/src/gdcmRLEFramesInfo.h
Removing Utilities/gdcm/src/gdcmSQItem.cxx
Removing Utilities/gdcm/src/gdcmSQItem.h
Removing Utilities/gdcm/src/gdcmSeqEntry.cxx
Removing Utilities/gdcm/src/gdcmSeqEntry.h
Removing Utilities/gdcm/src/gdcmSerieHelper.cxx
Removing Utilities/gdcm/src/gdcmSerieHelper.h
Removing Utilities/gdcm/src/gdcmTS.cxx
Removing Utilities/gdcm/src/gdcmTS.h
Removing Utilities/gdcm/src/gdcmUtil.cxx
Removing Utilities/gdcm/src/gdcmUtil.h
Removing Utilities/gdcm/src/gdcmVR.cxx
Removing Utilities/gdcm/src/gdcmVR.h
Removing Utilities/gdcm/src/gdcmValEntry.cxx
Removing Utilities/gdcm/src/gdcmValEntry.h
Removing Utilities/gdcm/src/gdcmValidator.cxx
Removing Utilities/gdcm/src/gdcmValidator.h
Removing Utilities/itkjpeg/12/CMakeLists.txt
Removing Utilities/itkjpeg/16/CMakeLists.txt
Removing Utilities/itkjpeg/8/CMakeLists.txt
Removing Utilities/itkjpeg/mangle_jpeg12bits.h
Removing Utilities/itkjpeg/mangle_jpeg16bits.h
Removing Utilities/itkjpeg/mangle_jpeg8bits.h
Pushing upstream master
To ../../ITK.git
Deleting fully merged topic 'integration-gdcm-2-0-16' (448bcde) from stage.

Integrating GDCM 2.x to ITK (the hard way)

Let's start from the begining:

$ git clone git://itk.org/ITK.git

install hooks and pushurl...

$ git checkout -b integration-gdcm-2-0-16

git status reval I now on branch integration-gdcm-2-0-16

HACK HACK
$ git commit
...

Now in order to share code with Mark Roden. I decided to push to my github account:

$ git remote add perso git@github.com:malaterre/ITK.git
$ git push perso integration-gdcm-2-0-16

After a couple of exchange the branch was properly compiling on Linux/Win32/MacOSX.
I was ready to push GDCM 2.x to ITK. As suggested by Brad Lowekamp I pushed to stage first:

$ git remote add stage git://itk.org/stage/ITK.git
$ git config remote.stage.pushurl git@itk.org:stage/ITK.git
$ git fetch stage --prune
$ git checkout integration-gdcm-2-0-16
$ git push stage HEAD

one can then print it:

$ ssh git@itk.org stage ITK print

I pushed it also to gerrit for review.

$ git log gerrit/master..
$ git push gerrit HEAD:refs/for/master/integration-gdcm-2-0-16

This lead to some discussion with Brad King.

$ git add CMake/ExportConfiguration/CMakeLists.txt CMakeLists.txt
$ git commit
$ git push gerrit d2ee19d:refs/changes/24
Counting objects: 14, done.
Delta compression using up to 16 threads.
Compressing objects: 100% (8/8), done.
Writing objects: 100% (8/8), 9.84 KiB, done.
Total 8 (delta 6), reused 0 (delta 0)
To malaterre@review.source.kitware.com:ITK
! [remote rejected] d2ee19d -> refs/changes/24 (squash commits first)
error: failed to push some refs to 'malaterre@review.source.kitware.com:ITK'

This was not quite right, I had to squash the last two commits:

$ git commit --amend
$ git push gerrit 1ddc92d:refs/changes/24
Counting objects: 14, done.
Delta compression using up to 16 threads.
Compressing objects: 100% (8/8), done.
Writing objects: 100% (8/8), 9.85 KiB, done.
Total 8 (delta 6), reused 0 (delta 0)
To malaterre@review.source.kitware.com:ITK
! [remote rejected] 1ddc92d -> refs/changes/24 (squash commits first)
error: failed to push some refs to 'malaterre@review.source.kitware.com:ITK'

Still not ! I need to actually edit the word 'pick' and change it to 'squash':

$ git rebase -i HEAD~2
$ git push gerrit 448bcde:refs/changes/24
Counting objects: 62, done.
Delta compression using up to 16 threads.
Compressing objects: 100% (35/35), done.
Writing objects: 100% (38/38), 21.88 KiB, done.
Total 38 (delta 25), reused 0 (delta 0)
To malaterre@review.source.kitware.com:ITK
* [new branch] 448bcde -> refs/changes/24

Now that the change are on gerrit, push them to stage too:

$ git push stage HEAD
To git@itk.org:stage/ITK.git
! [rejected] HEAD -> integration-gdcm-2-0-16 (non-fast-forward)
error: failed to push some refs to 'git@itk.org:stage/ITK.git'
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes before pushing again. See the 'Note about
fast-forwards' section of 'git push --help' for details.

Hum, something happen during the squash that made the push non-trivial on stage.

Meanwhile, let's push to my github account:

$ git push perso integration-gdcm-2-0-16

Thanks to Brad L., I tried it again:

$ git checkout integration-gdcm-2-0-16
$ git log master..
$ git push -f stage integration-gdcm-2-0-16
$ ssh git@itk.org stage ITK print
$ ssh git@itk.org stage ITK merge integration-gdcm-2-0-16

Finally all set ! Thanks to Brad K. and Brad L. !

References:
* http://www.itk.org/Wiki/ITK/Gerrit
* http://www.itk.org/Wiki/ITK/Git#Topic_Stage
* http://www.itk.org/Wiki/ITK/Git#Pushing

Saturday, April 10, 2010

Exporting the DICOM Standard to docbook

I have finally found sometime to update PS 3.3 XML in GDCM using the newest standard: PS 3.3 - 2009.

It seems however that there has been some internal changes in OpenOffice.org and the docbook export function does not work as well as it used to be.

For instance see this bug report:

http://www.openoffice.org/issues/show_bug.cgi?id=110762

Monday, December 14, 2009

PDF Library

In GDCM, I needed a PDF library in order to cope with Encapsulated PDF Storage (1.2.840.10008.5.1.4.1.1.104.1)

I thought poppler would fit the need, but anytime a new release would come out, the API would be badly broken. Eg:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=555959

Today I found out, there is a new effort:

http://planet.gnu.org/gnupdf/

I'll have to keep an eye on it, and drop poppler which is only a rendering library (it pulls dependencies to fonts library !).

RT Ion Plan Storage in GDCM




GDCM 2.x trunk now support loading or RT Ion Plan Storage (1.2.840.10008.5.1.4.1.1.481.8).

The code is available at:

http://gdcm.svn.sf.net/viewvc/gdcm/trunk/Utilities/VTK/Examples/Cxx/gdcmrtionplan.cxx?view=markup

Enjoy !

Monday, November 30, 2009

LC_NUMERIC

I was recently involved in a thread on ITK mailing list, where it was discussed the use of LC_NUMERIC. In DICOM it is very important to write floating point number in C-style format.

At first I thought I could test using:

http://groups.google.com/group/comp.lang.c++/browse_thread/thread/a881d87a65b260b7

well in fact it is much more complex:

http://gdcm.svn.sf.net/viewvc/gdcm/trunk/Testing/Source/DataStructureAndEncodingDefinition/Cxx/TestLCNumeric.cxx?view=markup

Now I can setup test to check whether GDCM is LC_NUMERIC independant or not !

Wednesday, November 25, 2009




You want the best from GDCM, but are you are using Activiz ? Well take the best from both.
You can now use GDCM directly from C# using the Activiz framework !

This image was a screenshot of:

$ mono ./bin/HelloActiviz3.exe ~/Creatis/gdcmData/012345.002.050.dcm

Enjoy.

Thursday, November 12, 2009

Private DICOM dictionary

Looking at the private dictionary for pydicom:

http://code.google.com/p/pydicom/

It says:

http://code.google.com/p/pydicom/source/browse/source/generate_dict/make_private_dict.py

...
# Generates output from a file from the MDCM project (http://code.google.com/p/mdcm),
...

The only issue is that mdcm is LGPL, while pydicom claims to be MIT... There is a clear conflict of license here.

So I filled in a bug report:

http://code.google.com/p/pydicom/issues/detail?id=61&colspec=ID%20Type%20Status%20Priority%20Milestone%20Owner%20Summary%20Difficulty

I cannot believe they prefered to used the dictionary from mdcm, instead of using the easy-to-parse XML dictionary from GDCM

http://gdcm.svn.sf.net/viewvc/gdcm/trunk/Source/DataDictionary/privatedicts.xml?view=markup

oh well...