{
  "id": 48285,
  "title": "How to train a CNN model with a common GPU",
  "url": "/competitions/sp-society-camera-model-identification/discussion/48285",
  "author_name": "",
  "post_date": "2018-01-25T17:13:52.993448200Z",
  "votes": null,
  "comment_count": 2,
  "views": 0,
  "content": "<p>I have just created a very simple CNN neural network with keras. But when running, it always hints that resource exhausted. I think memory consumption is too high or I shall say there is not enough gpu memory in my gpu card.</p>\n\n<p>I have reduced the batch size to 1. It still does not run.</p>\n\n<p>My input image is just 512x512.</p>\n\n<p>Does anyone hit similar issue and what is the solution?</p>",
  "messages": [
    {
      "id": "274021",
      "postDate": "01/25/2018 17:13:52",
      "content": "<p>I have just created a very simple CNN neural network with keras. But when running, it always hints that resource exhausted. I think memory consumption is too high or I shall say there is not enough gpu memory in my gpu card.</p>\n\n<p>I have reduced the batch size to 1. It still does not run.</p>\n\n<p>My input image is just 512x512.</p>\n\n<p>Does anyone hit similar issue and what is the solution?</p>",
      "rawMarkdown": "I have just created a very simple CNN neural network with keras. But when running, it always hints that resource exhausted. I think memory consumption is too high or I shall say there is not enough gpu memory in my gpu card.\n\nI have reduced the batch size to 1. It still does not run.\n\nMy input image is just 512x512.\n\nDoes anyone hit similar issue and what is the solution?",
      "votes": null
    },
    {
      "id": "274025",
      "postDate": "01/25/2018 17:16:58",
      "content": "<p>Okay, it works when I tweak the input image size to 128x128.</p>\n\n<p>But what is the solution if I still want the input size to be 512x512?</p>",
      "rawMarkdown": "Okay, it works when I tweak the input image size to 128x128.\n\nBut what is the solution if I still want the input size to be 512x512?",
      "votes": null
    },
    {
      "id": "274074",
      "postDate": "01/25/2018 21:19:57",
      "content": "<p>You may want to try this:\n<a href=\"https://github.com/openai/gradient-checkpointing\">https://github.com/openai/gradient-checkpointing</a></p>",
      "rawMarkdown": "You may want to try this:\nhttps://github.com/openai/gradient-checkpointing",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 274025,
      "author_name": "zhaoyangma",
      "author_url": "",
      "post_date": "01/25/2018 17:16:58",
      "content": "<p>Okay, it works when I tweak the input image size to 128x128.</p>\n\n<p>But what is the solution if I still want the input size to be 512x512?</p>",
      "votes": null,
      "replies": [
        {
          "id": 274074,
          "author_name": "antorsae",
          "author_url": "",
          "post_date": "01/25/2018 21:19:57",
          "content": "<p>You may want to try this:\n<a href=\"https://github.com/openai/gradient-checkpointing\">https://github.com/openai/gradient-checkpointing</a></p>",
          "votes": null,
          "replies": []
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "274021": "I have just created a very simple CNN neural network with keras. But when running, it always hints that resource exhausted. I think memory consumption is too high or I shall say there is not enough gpu memory in my gpu card.\n\nI have reduced the batch size to 1. It still does not run.\n\nMy input image is just 512x512.\n\nDoes anyone hit similar issue and what is the solution?",
    "274025": "Okay, it works when I tweak the input image size to 128x128.\n\nBut what is the solution if I still want the input size to be 512x512?",
    "274074": "You may want to try this:\nhttps://github.com/openai/gradient-checkpointing"
  },
  "source": "meta"
}