]> Creatis software - gdcm.git/commitdiff
* Cosmetic changes:
authorfrog <frog>
Tue, 16 Sep 2003 13:40:45 +0000 (13:40 +0000)
committerfrog <frog>
Tue, 16 Sep 2003 13:40:45 +0000 (13:40 +0000)
        - gdcmPython/testSuite.py adapted to the JPR updated Dicts/dicomV3.dic
          Dicom dictionary. The test suite can now be run again. Note:
          I'm note very happy with the " (RET)" changes. I believe this
          RETAINED comment should be dropped when parsing the dictionary.
        - PACKAGER corrected
        - DEVELOPPER added.
        - AUTHORS updated and now in alphabetical order

AUTHORS
ChangeLog
DEVELOPPER [new file with mode: 0644]
PACKAGER
gdcmPython/testSuite.py
setup.py

diff --git a/AUTHORS b/AUTHORS
index f84547f0dd8dd1ff44e4b0028ad1f2e6f827822f..b76fef28edaf22d62b0cfa8c1a8543422e9aa15b 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -1,5 +1,6 @@
-Jean-Pierre Roux
-Benoit Regrain
-Emmanuel Olart
-Leonardo Florez
+Florez Leonardo
 Frog
+Malaterre Mathieu
+Olart Emmanuel
+Regrain Benoit
+Roux Jean-Pierre
index 4993c111f7dc3e51114a05821c4965201ca6d87e..4ec1c6211c4cc10e2222dab7487aeec39c6dca4e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2003-09-16  Eric Boix <Eric.Boix@creatis.insa-lyon.fr> with JPR
+      * Cosmetic changes:
+        - gdcmPython/testSuite.py adapted to the JPR updated Dicts/dicomV3.dic
+          Dicom dictionary. The test suite can now be run again. Note:
+          I'm note very happy with the " (RET)" changes. I believe this
+          RETAINED comment should be dropped when parsing the dictionary. 
+        - PACKAGER corrected
+        - DEVELOPPER added.
+        - AUTHORS updated and now in alphabetical order
 2003-09-11  Mathieu Malaterre  <Mathieu.Malaterre@creatis.insa-lyon.fr>
       * cygwin complains about missing std:: in subdir Test/
 2003-09-10  Mathieu Malaterre  <Mathieu.Malaterre@creatis.insa-lyon.fr>
diff --git a/DEVELOPPER b/DEVELOPPER
new file mode 100644 (file)
index 0000000..f4fb12f
--- /dev/null
@@ -0,0 +1,46 @@
+The following comments are intended for core gdcm developpers.
+
+
+* Python related section.
+  Depending on the automake/autoconf/autogen.sh flags you used gdcm could
+  be wrapped in two ways:
+  - the first python wrappers of gdcm use Swig (http://www.swig.org). They
+    are the ones generated when using autogen.sh --enable-python. 
+    The entry point is here the file gdcmPython/gdcm.i which uses the
+    Swig synthax. As the last lines of this file (the ones starting
+    with the %include directive) only some classes are wrapped for python.
+    In theory only the library interface (basically the classes gdcmHeader
+    and gdcmFile) should be wrapped, but the time being some additional
+    classes are added (just to make sure those classes are Swig compatible:
+    swig is here used as some lint checker!?).
+    Since gdcm is written in C++, Swig will produce two different outups:
+      -- some C based low level wrapper (see gdcmPython/gdcm_wrap.c)
+      -- some Python based object oriented so called "shadow classes" (see
+         file gdcmPython/gdcm.py)
+    We also added the file gdcmPython/__init__.py which is the one that
+    actually gets loaded when ones uses the gdcmPython Python package.
+    The file __init__.py loads the swig generated shadow classes (gdcm.py)
+    but will only re-export the interface of gdcm which correponds to
+    the lines :
+       gdcmHeader = gdcm.gdcmHeader
+       gdcmDictSet = gdcm.gdcmDictSet
+       gdcmFile = gdcm.gdcmFile
+    Hence this whole Swig wrapping process is quite odd since we shall
+    wrap more classes (%include in swig.i) than eventually exported to
+    the final user by gdcmPython/__init__.py.
+  - the second python wrappers use the vtk (http://public.kitware.com/VTK/)
+    native wrappers i.e. the binary vtkWrapPython. But it should be noticed
+    that the purpous is here a bit different than the one of the Swig
+    generated Python wrappers. When using vtkWrapPython the goal is to
+    wrap a single vtk class namely vtkGdcmReader as defined in files
+    in vtk/vtkGdcmReader.h vtk/vtkGdcmReader.cxx (and of course those
+    files are hand made vtk oriented wrappers of gdcm).
+    Those wrappers are the one generated when using
+       autogen.sh --enable-python --enable-vtk
+  - In order to understand the difference between both wrappers you should 
+    compare both demo scripts gdcmPython/demo/vtkGdcmDemo.py and
+    gdcmPython/demo/vtkGdcmReader.py. The first one only uses the
+    Swig wraped classes ("from gdcmPython import gdcmHeader') as opposed
+    to vtkGdcmReader.py which also uses vtkWrapPython wraped classes
+    ("from gdcmPython.vtkgdcmPython import *").
+    
index d1775210be484efb6dec201abd7bfdb2e2008cf2..8b3b8227863974d46a51140bb00a46d853e3127c 100644 (file)
--- a/PACKAGER
+++ b/PACKAGER
@@ -34,6 +34,12 @@ Here is the checklist when freezing a version of gdcm:
          \rm -fr build /tmp/lib
        - Binary distribution:
          cd $GDCMHOME
+         make clean
+            [ or you migth get some complains about the function 
+              PyVTKClass_vtkGdcmReaderNew being multiply defined: this is
+              because of the loose definition of vtkSources in setup.py
+              in which the usage of the glob function will produce a link
+              stage with multiple occurences of vtkGdcmReaderPython.o)].
          python setup.py bdist --formats=rpm
          su
          rpm -Uvh dist/gdcmPython-0.*.i386.rpm
@@ -45,6 +51,7 @@ Here is the checklist when freezing a version of gdcm:
        - Source distribution and then binary distribution (out of build 
          source distro):
          cd $GDCMHOME
+         [make clean (see above) ]
          python setup.py sdist
          cd /tmp
          tar zxvf $GDCMHOME/dist/gdcmPython-*.tar.gz
index 8a19d58b6c6bf34c292abf92fcd416413da1abd8..c6fc0e1baaaf3b683f0c9a55f233dbe99b5579dc 100644 (file)
@@ -20,7 +20,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "9"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "FUJI PHOTO FILM CO. LTD."],
-           ["Manufacturer Model Name", "9000"],
+           ["Manufacturer's Model Name", "9000"],
            ["Pixel Data", "gdcm::NotLoaded. Address:776 Length:387200"] ] ],
       ####################################
       # CT modality examples:
@@ -35,7 +35,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "15"],
            ["Pixel Representation", "1"],
            ["Manufacturer", "Picker International, Inc."],
-           ["Manufacturer Model Name", "PQ5000"],
+           ["Manufacturer's Model Name", "PQ5000"],
            ["Pixel Data", "gdcm::NotLoaded. Address:1680 Length:524288"] ] ],
       ["CT-MONO2-16-ort.dcm",
          [ ["Transfer Syntax UID", "1.2.840.10008.1.2"],  # Implicit VR, LE
@@ -47,7 +47,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "15"],
            ["Pixel Representation", "1"],
            ["Manufacturer", "GE MEDICAL SYSTEMS"],
-           ["Manufacturer Model Name", "HiSpeed CT/i"],
+           ["Manufacturer's Model Name", "HiSpeed CT/i"],
            ["Pixel Data", "gdcm::NotLoaded. Address:1674 Length:524288"] ] ],
       ["CT-MONO2-16-ankle.dcm",
          [ ["Transfer Syntax UID", "1.2.840.10008.1.2"],  # Implicit, little
@@ -59,7 +59,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "15"],
            ["Pixel Representation", "1"],
            ["Manufacturer", "GE MEDICAL SYSTEMS"],
-           ["Manufacturer Model Name", "GENESIS_ZEUS"],
+           ["Manufacturer's Model Name", "GENESIS_ZEUS"],
            ["Pixel Data", "gdcm::NotLoaded. Address:1148 Length:524288"] ] ],
       ["CT-MONO2-8-abdo.dcm",
          [ ["Transfer Syntax UID", "1.2.840.10008.1.2"],  # Implicit, little
@@ -99,7 +99,7 @@ class gdcmTestCase(unittest.TestCase):
       ### MR modality examples:
       ####################################
       ["MR-MONO2-12-angio-an1.acr1",
-         [ ["Recognition Code", "ACR-NEMA 1.0"],
+         [ ["Recognition Code (RET)", "ACR-NEMA 1.0"],
            ["Modality", "MR"],
            #"Transfer Syntax UID" and "Photometric Interpretation" are absent.
            ["Rows", "256"],
@@ -121,7 +121,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "SIEMENS"],
-           ["Manufacturer Model Name", "MAGNETOM VISION"],
+           ["Manufacturer's Model Name", "MAGNETOM VISION"],
            ["Pixel Data", "gdcm::NotLoaded. Address:1866 Length:131072"] ] ],
       ["MR-MONO2-16-head.dcm",
          [ ["Transfer Syntax UID", "1.2.840.10008.1.2"], # Imp VR, LE
@@ -134,7 +134,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "15"],
            ["Pixel Representation", "1"],
            ["Manufacturer", "GE MEDICAL SYSTEMS"],
-           ["Manufacturer Model Name", "GENESIS_SIGNA"],
+           ["Manufacturer's Model Name", "GENESIS_SIGNA"],
            ["Pixel Data", "gdcm::NotLoaded. Address:1804 Length:131072"] ] ],
       # MR-MONO2-12-shoulder example is present in the Jpeg section.
       # MR-MONO2-16-knee is not present in the test suite since it is too
@@ -204,7 +204,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "7"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "G.E. Medical Systems"],
-           ["Manufacturer Model Name", "LOGIQ 700"],
+           ["Manufacturer's Model Name", "LOGIQ 700"],
          # + Planar configuration (0028,0006) = 1 --> Plane R, Plane G, Plane B  
            ["Implementation Version Name", "OFFIS-DCMTK-311"],
            ["Pixel Data", "gdcm::NotLoaded. Address:1012 Length:921600"] ] ],
@@ -289,7 +289,7 @@ class gdcmTestCase(unittest.TestCase):
    GdcmFiles = [
       ["gdcm-MR-SIEMENS-16.acr1",
          # Interest: good old Acr-Nema Version 1, see also Oddities below
-         [ ["Recognition Code", "ACR-NEMA 1.0"],
+         [ ["Recognition Code (RET)", "ACR-NEMA 1.0"],
            ["Modality", "MR"],
            ["Rows", "256"],
            ["Columns", "256"],
@@ -298,7 +298,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "SIEMENS"],
-           ["Manufacturer Model Name", "GBS III"],
+           ["Manufacturer's Model Name", "GBS III"],
          # FIXME: this image looks padded at the end. The length of the file
          # is 140288. Notice that, 256*256*2 + 1024 = 131072 + 1024 = 132096
            ["Pixel Data", "gdcm::NotLoaded. Address:8192 Length:132096"],
@@ -308,7 +308,7 @@ class gdcmTestCase(unittest.TestCase):
            # Oddities: "Study" and "Serie Instance UID" are not present
       ["gdcm-MR-SIEMENS-16.acr2",
          # Interest: Acr-Nema Version 2
-         [ ["Recognition Code", "ACR-NEMA 2.0"],
+         [ ["Recognition Code (RET)", "ACR-NEMA 2.0"],
            ["Modality", "MR"],
            ["Rows", "512"],
            ["Columns", "512"],
@@ -317,7 +317,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "SIEMENS"],
-           ["Manufacturer Model Name", "MAGNETOM VISION"],
+           ["Manufacturer's Model Name", "MAGNETOM VISION"],
            ["Study Instance UID",
             "1.3.12.2.1107.5.2.4.7630.20000918174641000"],
            ["Study ID", "1"],
@@ -331,7 +331,7 @@ class gdcmTestCase(unittest.TestCase):
          [ ["Transfer Syntax UID", "1.2.840.10008.1.2"],  # Implicit VR, LE
            ["Modality", "US"],
            ["Photometric Interpretation", "PALETTE COLOR"],
-           ["Segmented Green Palette Color LUT Data",
+           ["Segmented Green Palette Color Lookup Table Data",
             "gdcm::NotLoaded. Address:89576 Length:113784"],
            ["Rows", "480"],
            ["Columns", "640"],
@@ -340,13 +340,13 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "15"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "ALOKA CO., LTD."],
-           ["Manufacturer Model Name", "SSD-4000"],
+           ["Manufacturer's Model Name", "SSD-4000"],
            ["Pixel Data", "gdcm::NotLoaded. Address:258740 Length:614400"] ] ],
       ["gdcm-MR-PHILIPS-16.dcm",
          # Interest: - possesses a sequence
          #           - dicom file, with a recognition code of ACR-NEMA1
          [ ["Transfer Syntax UID", "1.2.840.10008.1.2"],  # Implicit VR, LE
-           ["Recognition Code", "ACR-NEMA 1.0"],
+           ["Recognition Code (RET)", "ACR-NEMA 1.0"],
            ["Modality", "MR"],
            ["Photometric Interpretation", "MONOCHROME2"],
            ["Rows", "256"],
@@ -356,7 +356,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "7"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "Philips Medical Systems"],
-           ["Manufacturer Model Name", "Gyroscan Intera"],
+           ["Manufacturer's Model Name", "Gyroscan Intera"],
            ["Sequence Variant", "OTHER"],
            ["Pixel Data", "gdcm::NotLoaded. Address:6584 Length:131072"] ] ],
       ["gdcm-MR-PHILIPS-16-Multi-Seq.dcm",
@@ -364,7 +364,7 @@ class gdcmTestCase(unittest.TestCase):
          #           - Big sequence 28808 bytes at (0x0029, 0x263d)
          #           - dicom file, with a recognition code of ACR-NEMA1
          [ ["Transfer Syntax UID", "1.2.840.10008.1.2.1"],
-           ["Recognition Code", "ACR-NEMA 1.0"],
+           ["Recognition Code (RET)", "ACR-NEMA 1.0"],
            ["Modality", "MR"],
            ["Photometric Interpretation", "MONOCHROME2"],
            ["Rows", "128"],
@@ -374,7 +374,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "Philips Medical Systems"],
-           ["Manufacturer Model Name", "Gyroscan Intera"],
+           ["Manufacturer's Model Name", "Gyroscan Intera"],
            ["Sequence Variant", "OTHER"],
            ["Pixel Data", "gdcm::NotLoaded. Address:35846 Length:32768"] ] ],
       ["gdcm-MR-PHILIPS-16-NonRectPix.dcm",
@@ -390,7 +390,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "Philips Medical Systems"],
-           ["Manufacturer Model Name", "Gyroscan Intera"],
+           ["Manufacturer's Model Name", "Gyroscan Intera"],
            ["Pixel Spacing", "0.487416\\0.194966"],
            ["Pixel Data", "gdcm::NotLoaded. Address:5010 Length:20480"] ] ],
       ["gdcm-CR-DCMTK-16-NonSamplePerPix.dcm",
@@ -423,7 +423,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "SIEMENS"],
-           ["Manufacturer Model Name", "Volume Zoom"],
+           ["Manufacturer's Model Name", "Volume Zoom"],
            ["Pixel Data", "gdcm::NotLoaded. Address:2946 Length:192218"] ] ],
       ["MR-MONO2-12-shoulder.dcm",
          # Interest: Jpeg compression [Lossless, non-hierar. (14)]
@@ -437,7 +437,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "Philips Medical Systems"],
-           ["Manufacturer Model Name", "Gyroscan NT"],
+           ["Manufacturer's Model Name", "Gyroscan NT"],
            ["Pixel Data", "gdcm::NotLoaded. Address:1580 Length:718948"] ] ],
       ["gdcm-JPEG-LossLess3a.dcm",
          # Interest: - Jpeg compression [Lossless, hierar., first-order
@@ -454,7 +454,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "11"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "SIEMENS"],
-           ["Manufacturer Model Name", "Volume Zoom"] ] ],
+           ["Manufacturer's Model Name", "Volume Zoom"] ] ],
          # FIXME: the pixel data looks like corrupted. As stated by "od -A d -c"
          #   0002528     à 177 020 \0  O  B \0 \0   ÿ  ÿ   ÿ   ÿ  þ  ÿ \0  à
          #   0002544    \0  \0  \0 \0  þ  ÿ \0  à 202  ? 003  \0  ÿ  Ø  ÿ  Ã
@@ -492,7 +492,7 @@ class gdcmTestCase(unittest.TestCase):
            ["High Bit", "14"],
            ["Pixel Representation", "0"],
            ["Manufacturer", "Philips Medical Systems"],
-           ["Manufacturer Model Name", "Cassette Holder Type 9840 500 35201"],
+           ["Manufacturer's Model Name", "Cassette Holder Type 9840 500 35201"],
            ["Pixel Data", "gdcm::NotLoaded. Address:3144 Length:4795668"] ] ],
    ]
 
index 275fc6d8b596d87a364fed8d76b81c55fb466025..8dfa2f234dcab7ade6a442cac6d33ade043df2e7 100644 (file)
--- a/setup.py
+++ b/setup.py
@@ -7,8 +7,8 @@ from WrapVTK import *
 ThisModule='gdcmPython'
 gdcmPythonSrcDir=ThisModule
 gdcmSrcDir      ="src"
-gdcmJpeg8SrcDir  =os.path.join('src', 'jpeg', 'libijg8')
-gdcmJpeg12SrcDir  =os.path.join('src', 'jpeg', 'libijg12')
+gdcmJpeg8SrcDir =os.path.join('src', 'jpeg', 'libijg8')
+gdcmJpeg12SrcDir=os.path.join('src', 'jpeg', 'libijg12')
 gdcmvtkSrcDir   ="vtk"
 gdcmDictsDir    ="Dicts"
 gdcmTestDir     ="Test"