{
  "id": 236768,
  "title": "Unable to leverage GPU",
  "url": "/competitions/birdclef-2021/discussion/236768",
  "author_name": "",
  "post_date": "2021-05-05T17:58:24.367939300Z",
  "votes": 2,
  "comment_count": 6,
  "views": 0,
  "content": "<p>Hi!</p>\n<p>I'm new here. I started off by building a basic pipeline for myself for this competition using TF2. However, when I turn on the GPU, it is always utilized 0%. I've tried other resources on the internet like using \"with tf.device('/device:GPU:0')\" but nothing seems to work out. </p>\n<p>PS: I've built a custom data generator. Does that have to do anything with this?</p>\n<p>I request you guys to help me here, please.</p>\n<p>Thanks!</p>",
  "messages": [
    {
      "id": "1294524",
      "postDate": "05/05/2021 17:58:24",
      "content": "<p>Hi!</p>\n<p>I'm new here. I started off by building a basic pipeline for myself for this competition using TF2. However, when I turn on the GPU, it is always utilized 0%. I've tried other resources on the internet like using \"with tf.device('/device:GPU:0')\" but nothing seems to work out. </p>\n<p>PS: I've built a custom data generator. Does that have to do anything with this?</p>\n<p>I request you guys to help me here, please.</p>\n<p>Thanks!</p>",
      "rawMarkdown": "Hi!\n\nI'm new here. I started off by building a basic pipeline for myself for this competition using TF2. However, when I turn on the GPU, it is always utilized 0%. I've tried other resources on the internet like using \"with tf.device('/device:GPU:0')\" but nothing seems to work out. \n\nPS: I've built a custom data generator. Does that have to do anything with this?\n\nI request you guys to help me here, please.\n\nThanks!",
      "votes": null
    },
    {
      "id": "1294628",
      "postDate": "05/05/2021 19:32:18",
      "content": "<p>use this command check whether gpu is been listed 1st?<br>\nprint(\"Num GPUs Available: \", len(tf.config.list_physical_devices('GPU')))</p>",
      "rawMarkdown": "use this command check whether gpu is been listed 1st?\nprint(\"Num GPUs Available: \", len(tf.config.list_physical_devices('GPU')))",
      "votes": null
    },
    {
      "id": "1295040",
      "postDate": "05/06/2021 06:50:39",
      "content": "<p>Thanks for the response Arunodhayan. I had checked it and it was available. Is there some way I can explicitly make TF use GPU? \"with tf.device('/device:GPU:0')\" didn't work.</p>",
      "rawMarkdown": "Thanks for the response Arunodhayan. I had checked it and it was available. Is there some way I can explicitly make TF use GPU? \"with tf.device('/device:GPU:0')\" didn't work.",
      "votes": null
    },
    {
      "id": "1295638",
      "postDate": "05/06/2021 15:44:54",
      "content": "<p><a href=\"https://www.kaggle.com/yashraizada\" target=\"_blank\">@yashraizada</a> better try to reinstall tensorflow with the correct cuda because sometime tf with wrong cuda might not select GPU for training </p>",
      "rawMarkdown": "yashraizada better try to reinstall tensorflow with the correct cuda because sometime tf with wrong cuda might not select GPU for training",
      "votes": null
    },
    {
      "id": "1295796",
      "postDate": "05/06/2021 17:42:26",
      "content": "<p>Where are you running TF?  Did you install it yourself?  In that case, are you should you did not install the cpu version of TF?</p>",
      "rawMarkdown": "Where are you running TF?  Did you install it yourself?  In that case, are you should you did not install the cpu version of TF?",
      "votes": null
    },
    {
      "id": "1296761",
      "postDate": "05/07/2021 13:41:26",
      "content": "<p>I'm running it on Kaggle notebooks. I'm attaching the screenshots of the issue here:</p>\n<ol>\n<li><a href=\"https://drive.google.com/file/d/15U7sQwyzVSEswu6NUhfNACYzsgzsXYj3/view?usp=sharing\" target=\"_blank\">https://drive.google.com/file/d/15U7sQwyzVSEswu6NUhfNACYzsgzsXYj3/view?usp=sharing</a></li>\n<li><a href=\"https://drive.google.com/file/d/1Ce4tZO-QY2_d7Xb_nHgkBNVms9LlgLeD/view?usp=sharing\" target=\"_blank\">https://drive.google.com/file/d/1Ce4tZO-QY2_d7Xb_nHgkBNVms9LlgLeD/view?usp=sharing</a></li>\n</ol>\n<p>Thanks</p>",
      "rawMarkdown": "I'm running it on Kaggle notebooks. I'm attaching the screenshots of the issue here:\n1. https://drive.google.com/file/d/15U7sQwyzVSEswu6NUhfNACYzsgzsXYj3/view?usp=sharing\n2. https://drive.google.com/file/d/1Ce4tZO-QY2_d7Xb_nHgkBNVms9LlgLeD/view?usp=sharing\n\nThanks",
      "votes": null
    },
    {
      "id": "1296932",
      "postDate": "05/07/2021 15:29:22",
      "content": "<p>it states access denied, you can try reinstalling tensorflow with GPU support</p>",
      "rawMarkdown": "it states access denied, you can try reinstalling tensorflow with GPU support",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 1294628,
      "author_name": "arunodhayan",
      "author_url": "",
      "post_date": "05/05/2021 19:32:18",
      "content": "<p>use this command check whether gpu is been listed 1st?<br>\nprint(\"Num GPUs Available: \", len(tf.config.list_physical_devices('GPU')))</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1295040,
      "author_name": "yashraizada",
      "author_url": "",
      "post_date": "05/06/2021 06:50:39",
      "content": "<p>Thanks for the response Arunodhayan. I had checked it and it was available. Is there some way I can explicitly make TF use GPU? \"with tf.device('/device:GPU:0')\" didn't work.</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1295638,
      "author_name": "arunodhayan",
      "author_url": "",
      "post_date": "05/06/2021 15:44:54",
      "content": "<p><a href=\"https://www.kaggle.com/yashraizada\" target=\"_blank\">@yashraizada</a> better try to reinstall tensorflow with the correct cuda because sometime tf with wrong cuda might not select GPU for training </p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1295796,
      "author_name": "cpmpml",
      "author_url": "",
      "post_date": "05/06/2021 17:42:26",
      "content": "<p>Where are you running TF?  Did you install it yourself?  In that case, are you should you did not install the cpu version of TF?</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1296761,
      "author_name": "yashraizada",
      "author_url": "",
      "post_date": "05/07/2021 13:41:26",
      "content": "<p>I'm running it on Kaggle notebooks. I'm attaching the screenshots of the issue here:</p>\n<ol>\n<li><a href=\"https://drive.google.com/file/d/15U7sQwyzVSEswu6NUhfNACYzsgzsXYj3/view?usp=sharing\" target=\"_blank\">https://drive.google.com/file/d/15U7sQwyzVSEswu6NUhfNACYzsgzsXYj3/view?usp=sharing</a></li>\n<li><a href=\"https://drive.google.com/file/d/1Ce4tZO-QY2_d7Xb_nHgkBNVms9LlgLeD/view?usp=sharing\" target=\"_blank\">https://drive.google.com/file/d/1Ce4tZO-QY2_d7Xb_nHgkBNVms9LlgLeD/view?usp=sharing</a></li>\n</ol>\n<p>Thanks</p>",
      "votes": null,
      "replies": [
        {
          "id": 1296932,
          "author_name": "arunodhayan",
          "author_url": "",
          "post_date": "05/07/2021 15:29:22",
          "content": "<p>it states access denied, you can try reinstalling tensorflow with GPU support</p>",
          "votes": null,
          "replies": []
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "1294524": "Hi!\n\nI'm new here. I started off by building a basic pipeline for myself for this competition using TF2. However, when I turn on the GPU, it is always utilized 0%. I've tried other resources on the internet like using \"with tf.device('/device:GPU:0')\" but nothing seems to work out. \n\nPS: I've built a custom data generator. Does that have to do anything with this?\n\nI request you guys to help me here, please.\n\nThanks!",
    "1294628": "use this command check whether gpu is been listed 1st?\nprint(\"Num GPUs Available: \", len(tf.config.list_physical_devices('GPU')))",
    "1295040": "Thanks for the response Arunodhayan. I had checked it and it was available. Is there some way I can explicitly make TF use GPU? \"with tf.device('/device:GPU:0')\" didn't work.",
    "1295638": "yashraizada better try to reinstall tensorflow with the correct cuda because sometime tf with wrong cuda might not select GPU for training",
    "1295796": "Where are you running TF?  Did you install it yourself?  In that case, are you should you did not install the cpu version of TF?",
    "1296761": "I'm running it on Kaggle notebooks. I'm attaching the screenshots of the issue here:\n1. https://drive.google.com/file/d/15U7sQwyzVSEswu6NUhfNACYzsgzsXYj3/view?usp=sharing\n2. https://drive.google.com/file/d/1Ce4tZO-QY2_d7Xb_nHgkBNVms9LlgLeD/view?usp=sharing\n\nThanks",
    "1296932": "it states access denied, you can try reinstalling tensorflow with GPU support"
  },
  "source": "meta"
}