suever / pydicom-experimental

pydicom test
0 stars 1 forks source link

_pixel_data_numpy in dataset does not respect Planar Configuration #150

Open suever opened 9 years ago

suever commented 9 years ago

From arothb...@4combinator.com on July 03, 2014 11:15:29

See: https://www.medicalconnections.co.uk/kb/Planar_configuration for a definition of the field tag. It appears that the reshaping assumes that Planar Configuration=1.

Original issue: http://code.google.com/p/pydicom/issues/detail?id=150

suever commented 9 years ago

From darcymason@gmail.com on November 02, 2014 12:47:07

Going through the issues list, coming back to this. Does anyone have example files that illustrate type 0? It should be fixable with a numpy rearrangement of the data, but it would be good to have examples to confirm correct behaviour.

Status: Accepted

suever commented 9 years ago

From arothb...@4combinator.com on November 02, 2014 12:53:47

I think you can convert a file from one format to another using dcmdjpeg

planar configuration options:

      +pa   --planar-auto
              automatically determine planar configuration
              from SOP class and color space (default)

      # If the compressed image is a color image, store in color-by-plane
      # planar configuration if required by the SOP class and photometric
      # interpretation. Hardcopy Color images are always stored color-by-
      # plane, and the revised Ultrasound image objects are stored color-by-
      # plane if the color model is YBR_FULL.  Everything else is stored
      # color-by-pixel.

      +px   --color-by-pixel
              always store color-by-pixel

      # If the compressed image is a color image, store in color-by-pixel
      # planar configuration.

      +pl   --color-by-plane
              always store color-by-plane

      # If the compressed image is a color image, store in color-by-plane
      # planar configuration.