{
  "id": 171595,
  "title": "A runtime error occurred recently: Interger division of tensors use div ...",
  "url": "/competitions/global-wheat-detection/discussion/171595",
  "author_name": "",
  "post_date": "2020-08-01T16:27:17.295890500Z",
  "votes": 8,
  "comment_count": 7,
  "views": 0,
  "content": "<p>Before time, my notebook work ok. But last day, I run it again and get \n&gt; RuntimeError: Integer division of tensors using div or / is no longer supported, and in a future release div will perform true division as in Python 3. Use true_divide or floor_divide (// in Python) instead.</p>\n\n<p><img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-user-content/o/inbox%2F825927%2F4f050d17a7b189344613821780dbd9c4%2FCapture.PNG?generation=1596299425299183&amp;alt=media\" alt=\"\"></p>\n\n<p>Maybe, because the new version of any packages. \nAnyone get this issue, please tell me how to fix it. \nThanks.</p>",
  "messages": [
    {
      "id": "954327",
      "postDate": "08/01/2020 16:27:17",
      "content": "<p>Before time, my notebook work ok. But last day, I run it again and get \n&gt; RuntimeError: Integer division of tensors using div or / is no longer supported, and in a future release div will perform true division as in Python 3. Use true_divide or floor_divide (// in Python) instead.</p>\n\n<p><img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-user-content/o/inbox%2F825927%2F4f050d17a7b189344613821780dbd9c4%2FCapture.PNG?generation=1596299425299183&amp;alt=media\" alt=\"\"></p>\n\n<p>Maybe, because the new version of any packages. \nAnyone get this issue, please tell me how to fix it. \nThanks.</p>",
      "rawMarkdown": "Before time, my notebook work ok. But last day, I run it again and get \n&gt; RuntimeError: Integer division of tensors using div or / is no longer supported, and in a future release div will perform true division as in Python 3. Use true_divide or floor_divide (// in Python) instead.\n\n![](https://www.googleapis.com/download/storage/v1/b/kaggle-user-content/o/inbox%2F825927%2F4f050d17a7b189344613821780dbd9c4%2FCapture.PNG?generation=1596299425299183&amp;alt=media)\n\n\nMaybe, because the new version of any packages. \nAnyone get this issue, please tell me how to fix it. \nThanks.",
      "votes": null
    },
    {
      "id": "954434",
      "postDate": "08/01/2020 18:14:27",
      "content": "<p>Yes, I just got this error too. I assume that Colab updated their python interpreter or something. To fix, I simply edited the bench.py to use <code>//</code> rather than <code>/</code>. Note that after editing, you must fully restart your session for the change to take effect.</p>",
      "rawMarkdown": "Yes, I just got this error too. I assume that Colab updated their python interpreter or something. To fix, I simply edited the bench.py to use `//` rather than `/`. Note that after editing, you must fully restart your session for the change to take effect.",
      "votes": null
    },
    {
      "id": "954693",
      "postDate": "08/02/2020 02:18:27",
      "content": "<p>Thank you , it works😊 </p>",
      "rawMarkdown": "Thank you , it works😊",
      "votes": null
    },
    {
      "id": "955027",
      "postDate": "08/02/2020 08:58:29",
      "content": "<p>Thank you <a href=\"/matthewmasters\">@matthewmasters</a> 💯 </p>",
      "rawMarkdown": "Thank you @matthewmasters 💯",
      "votes": null
    },
    {
      "id": "955058",
      "postDate": "08/02/2020 09:36:20",
      "content": "<p>Try this,</p>\n\n<p>!pip install torch==1.5.0+cu101 torchvision==0.6.0+cu101 -f <a href=\"https://download.pytorch.org/whl/torch_stable.html\">https://download.pytorch.org/whl/torch_stable.html</a></p>",
      "rawMarkdown": "Try this,\n\n!pip install torch==1.5.0+cu101 torchvision==0.6.0+cu101 -f https://download.pytorch.org/whl/torch_stable.html",
      "votes": null
    },
    {
      "id": "955101",
      "postDate": "08/02/2020 10:38:06",
      "content": "<p>Yeah, torch &gt;= 1.6.0 effected. The apex team should release the new version too.\nAnd I confirm it also works with </p>\n\n<blockquote>\n  <p>!pip install torch==1.5.1+cu101 torchvision==0.6.1+cu101 -f <a href=\"https://download.pytorch.org/whl/torch_stable.html\">https://download.pytorch.org/whl/torch_stable.html</a></p>\n</blockquote>",
      "rawMarkdown": "Yeah, torch &gt;= 1.6.0 effected. The apex team should release the new version too.\nAnd I confirm it also works with \n&gt; !pip install torch==1.5.1+cu101 torchvision==0.6.1+cu101 -f https://download.pytorch.org/whl/torch_stable.html",
      "votes": null
    },
    {
      "id": "956098",
      "postDate": "08/03/2020 08:33:37",
      "content": "<p>Hello, I have the same problem, where can I find the bench.py file in Colab?</p>",
      "rawMarkdown": "Hello, I have the same problem, where can I find the bench.py file in Colab?",
      "votes": null
    },
    {
      "id": "956521",
      "postDate": "08/03/2020 15:19:00",
      "content": "<p>My attachment file showed it ~ efficientdet_pytorch/effdet/bench.py</p>",
      "rawMarkdown": "My attachment file showed it ~ efficientdet_pytorch/effdet/bench.py",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 954434,
      "author_name": "matthewmasters",
      "author_url": "",
      "post_date": "08/01/2020 18:14:27",
      "content": "<p>Yes, I just got this error too. I assume that Colab updated their python interpreter or something. To fix, I simply edited the bench.py to use <code>//</code> rather than <code>/</code>. Note that after editing, you must fully restart your session for the change to take effect.</p>",
      "votes": null,
      "replies": [
        {
          "id": 954693,
          "author_name": "maibakeer",
          "author_url": "",
          "post_date": "08/02/2020 02:18:27",
          "content": "<p>Thank you , it works😊 </p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 955027,
          "author_name": "truonghoang",
          "author_url": "",
          "post_date": "08/02/2020 08:58:29",
          "content": "<p>Thank you <a href=\"/matthewmasters\">@matthewmasters</a> 💯 </p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 956098,
          "author_name": "alucchi",
          "author_url": "",
          "post_date": "08/03/2020 08:33:37",
          "content": "<p>Hello, I have the same problem, where can I find the bench.py file in Colab?</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 956521,
          "author_name": "truonghoang",
          "author_url": "",
          "post_date": "08/03/2020 15:19:00",
          "content": "<p>My attachment file showed it ~ efficientdet_pytorch/effdet/bench.py</p>",
          "votes": null,
          "replies": []
        }
      ]
    },
    {
      "id": 955058,
      "author_name": "alanchen1115",
      "author_url": "",
      "post_date": "08/02/2020 09:36:20",
      "content": "<p>Try this,</p>\n\n<p>!pip install torch==1.5.0+cu101 torchvision==0.6.0+cu101 -f <a href=\"https://download.pytorch.org/whl/torch_stable.html\">https://download.pytorch.org/whl/torch_stable.html</a></p>",
      "votes": null,
      "replies": [
        {
          "id": 955101,
          "author_name": "truonghoang",
          "author_url": "",
          "post_date": "08/02/2020 10:38:06",
          "content": "<p>Yeah, torch &gt;= 1.6.0 effected. The apex team should release the new version too.\nAnd I confirm it also works with </p>\n\n<blockquote>\n  <p>!pip install torch==1.5.1+cu101 torchvision==0.6.1+cu101 -f <a href=\"https://download.pytorch.org/whl/torch_stable.html\">https://download.pytorch.org/whl/torch_stable.html</a></p>\n</blockquote>",
          "votes": null,
          "replies": []
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "954327": "Before time, my notebook work ok. But last day, I run it again and get \n&gt; RuntimeError: Integer division of tensors using div or / is no longer supported, and in a future release div will perform true division as in Python 3. Use true_divide or floor_divide (// in Python) instead.\n\n![](https://www.googleapis.com/download/storage/v1/b/kaggle-user-content/o/inbox%2F825927%2F4f050d17a7b189344613821780dbd9c4%2FCapture.PNG?generation=1596299425299183&amp;alt=media)\n\n\nMaybe, because the new version of any packages. \nAnyone get this issue, please tell me how to fix it. \nThanks.",
    "954434": "Yes, I just got this error too. I assume that Colab updated their python interpreter or something. To fix, I simply edited the bench.py to use `//` rather than `/`. Note that after editing, you must fully restart your session for the change to take effect.",
    "954693": "Thank you , it works😊",
    "955027": "Thank you @matthewmasters 💯",
    "955058": "Try this,\n\n!pip install torch==1.5.0+cu101 torchvision==0.6.0+cu101 -f https://download.pytorch.org/whl/torch_stable.html",
    "955101": "Yeah, torch &gt;= 1.6.0 effected. The apex team should release the new version too.\nAnd I confirm it also works with \n&gt; !pip install torch==1.5.1+cu101 torchvision==0.6.1+cu101 -f https://download.pytorch.org/whl/torch_stable.html",
    "956098": "Hello, I have the same problem, where can I find the bench.py file in Colab?",
    "956521": "My attachment file showed it ~ efficientdet_pytorch/effdet/bench.py"
  },
  "source": "meta"
}