{
  "id": 183780,
  "title": "RuntimeError: ... missing required dependencies: GDCM (req. GDCM)",
  "url": "/competitions/rsna-str-pulmonary-embolism-detection/discussion/183780",
  "author_name": "Susumu Oda",
  "post_date": "2020-09-18T02:08:25.420000",
  "votes": 0,
  "comment_count": 3,
  "views": 0,
  "content": "<p>Hi,</p>\n<pre><code>import pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n</code></pre>\n<p>gives</p>\n<blockquote>\n  <p>RuntimeError: The following handlers are available to decode the pixel data however they are missing required dependencies: GDCM (req. GDCM)</p>\n</blockquote>\n<pre><code>!conda install -c conda-forge gdcm -y\n!pip install pylibjpeg pylibjpeg-libjpeg\n\nimport pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n</code></pre>\n<p>sometimes work but not always.</p>\n<p><a href=\"https://www.kaggle.com/c/osic-pulmonary-fibrosis-progression/discussion/170710\" target=\"_blank\">https://www.kaggle.com/c/osic-pulmonary-fibrosis-progression/discussion/170710</a></p>\n<p>Cheers,<br>\nSusumu</p>",
  "messages": [
    {
      "id": 1015483,
      "postDate": "2020-09-18T08:08:41.893Z",
      "content": "<p><code>!conda install -c conda-forge gdcm</code>   resolves this issue for me. </p>",
      "rawMarkdown": "`!conda install -c conda-forge gdcm`   resolves this issue for me. ",
      "votes": 1
    },
    {
      "id": 1035919,
      "postDate": "2020-10-03T08:29:31.203Z",
      "content": "<p>Installing gdcm following the direction fixed the issue! <br>\n<a href=\"https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet\" target=\"_blank\"></a><a href=\"https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet\" target=\"_blank\">https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet</a><br>\nBefore, I was throwing out data points that were causing the same error as yours, so hope this solution helps </p>",
      "rawMarkdown": "Installing gdcm following the direction fixed the issue! \n[https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet\n](https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet)Before, I was throwing out data points that were causing the same error as yours, so hope this solution helps "
    },
    {
      "id": 1015376,
      "postDate": "2020-09-18T06:36:14.843Z",
      "content": "<p>Yes, I noticed the same problem, even when we use the <code>force=True</code> option in <code>pydicom.read_file</code>.</p>",
      "rawMarkdown": "Yes, I noticed the same problem, even when we use the `force=True` option in `pydicom.read_file`."
    },
    {
      "id": 1015157,
      "postDate": "2020-09-18T02:08:25.420Z",
      "content": "<p>Hi,</p>\n<pre><code>import pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n</code></pre>\n<p>gives</p>\n<blockquote>\n  <p>RuntimeError: The following handlers are available to decode the pixel data however they are missing required dependencies: GDCM (req. GDCM)</p>\n</blockquote>\n<pre><code>!conda install -c conda-forge gdcm -y\n!pip install pylibjpeg pylibjpeg-libjpeg\n\nimport pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n</code></pre>\n<p>sometimes work but not always.</p>\n<p><a href=\"https://www.kaggle.com/c/osic-pulmonary-fibrosis-progression/discussion/170710\" target=\"_blank\">https://www.kaggle.com/c/osic-pulmonary-fibrosis-progression/discussion/170710</a></p>\n<p>Cheers,<br>\nSusumu</p>",
      "rawMarkdown": "Hi,\n\n```\nimport pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n```\ngives\n> RuntimeError: The following handlers are available to decode the pixel data however they are missing required dependencies: GDCM (req. GDCM)\n```\n!conda install -c conda-forge gdcm -y\n!pip install pylibjpeg pylibjpeg-libjpeg\n\nimport pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n```\nsometimes work but not always.\n\nhttps://www.kaggle.com/c/osic-pulmonary-fibrosis-progression/discussion/170710\n\nCheers,\nSusumu"
    }
  ],
  "comments": [
    {
      "id": 1015483,
      "author_name": "SumanSudhir",
      "author_url": "",
      "post_date": "2020-09-18T08:08:41.893000",
      "content": "<p><code>!conda install -c conda-forge gdcm</code>   resolves this issue for me. </p>",
      "votes": 1,
      "replies": []
    },
    {
      "id": 1035919,
      "author_name": "권 진혁 (Jin Kwon)",
      "author_url": "",
      "post_date": "2020-10-03T08:29:31.203000",
      "content": "<p>Installing gdcm following the direction fixed the issue! <br>\n<a href=\"https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet\" target=\"_blank\"></a><a href=\"https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet\" target=\"_blank\">https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet</a><br>\nBefore, I was throwing out data points that were causing the same error as yours, so hope this solution helps </p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 1015376,
      "author_name": "Ronaldo S.A. Batista",
      "author_url": "",
      "post_date": "2020-09-18T06:36:14.843000",
      "content": "<p>Yes, I noticed the same problem, even when we use the <code>force=True</code> option in <code>pydicom.read_file</code>.</p>",
      "votes": 0,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "1015483": "`!conda install -c conda-forge gdcm`   resolves this issue for me. ",
    "1035919": "Installing gdcm following the direction fixed the issue! \n[https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet\n](https://www.kaggle.com/richardepstein/load-gdcm-in-notebook-without-internet)Before, I was throwing out data points that were causing the same error as yours, so hope this solution helps ",
    "1015376": "Yes, I noticed the same problem, even when we use the `force=True` option in `pydicom.read_file`.",
    "1015157": "Hi,\n\n```\nimport pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n```\ngives\n> RuntimeError: The following handlers are available to decode the pixel data however they are missing required dependencies: GDCM (req. GDCM)\n```\n!conda install -c conda-forge gdcm -y\n!pip install pylibjpeg pylibjpeg-libjpeg\n\nimport pydicom\nimport matplotlib.pyplot as plt\n\nimg = pydicom.read_file('/kaggle/input/rsna-str-pulmonary-embolism-detection/train/8bc04c1a5852/b3f09354bb04/ecdfcd5104b6.dcm')\nplt.imshow(img.pixel_array)\nplt.show()\n```\nsometimes work but not always.\n\nhttps://www.kaggle.com/c/osic-pulmonary-fibrosis-progression/discussion/170710\n\nCheers,\nSusumu"
  }
}