{
  "id": 18409,
  "title": "1st place solution - deepsense.io",
  "url": "/competitions/noaa-right-whale-recognition/writeups/deepsense-io-1st-place-solution-deepsense-io",
  "author_name": "",
  "post_date": "2016-01-25T21:40:35.520Z",
  "votes": 37,
  "comment_count": 21,
  "views": 6767,
  "content": "<p>Here's a blog post outlining our approach: <a href=\"http://deepsense.io/deep-learning-right-whale-recognition-kaggle/\">http://deepsense.io/deep-learning-right-whale-recognition-kaggle/</a>.</p>\n\n<p>Source code (and some trained models) can be found at <a href=\"https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1\">https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1</a>.</p>",
  "messages": [
    {
      "id": "104784",
      "postDate": "01/16/2016 15:38:19",
      "content": "<p>Here's a blog post outlining our approach: <a href=\"http://deepsense.io/deep-learning-right-whale-recognition-kaggle/\">http://deepsense.io/deep-learning-right-whale-recognition-kaggle/</a>.</p>\n\n<p>Source code (and some trained models) can be found at <a href=\"https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1\">https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1</a>.</p>",
      "rawMarkdown": "Here's a blog post outlining our approach: http://deepsense.io/deep-learning-right-whale-recognition-kaggle/.\r\n\r\nSource code (and some trained models) can be found at https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1.",
      "votes": null
    },
    {
      "id": "104789",
      "postDate": "01/16/2016 16:26:13",
      "content": "<p>Congratulations and thanks for sharing. </p>",
      "rawMarkdown": "Congratulations and thanks for sharing.",
      "votes": null
    },
    {
      "id": "104868",
      "postDate": "01/17/2016 15:24:06",
      "content": "<p>Excellent work, and thanks for the detailed blog post! It demonstrates a very pragmatic attitude (i.e. cutting corners when you need to, but being well aware of it) that I think is essential to do well on Kaggle. The resulting model is especially interesting to me because my approach is usually to let the networks figure everything out (especially w.r.t. rotation) -- but clearly in this competition that simply wasn't feasible.</p>\n\n<p>One thing I'm curious about is what the resulting top-k accuracy looks like. Cross-entropy is always a bit difficult to interpret, and top-10 accuracy might be more indicative of the practical applicability of the approach. It would be great if the competition organisers could share some numbers on this, like the organisers of the National Data Science Bowl did last year ( <a href=\"https://www.kaggle.com/c/datasciencebowl/forums/t/12995/classification-accuracy-in-top-10-teams\">https://www.kaggle.com/c/datasciencebowl/forums/t/12995/classification-accuracy-in-top-10-teams</a> ).</p>\n\n<p>Congratulations!</p>",
      "rawMarkdown": "Excellent work, and thanks for the detailed blog post! It demonstrates a very pragmatic attitude (i.e. cutting corners when you need to, but being well aware of it) that I think is essential to do well on Kaggle. The resulting model is especially interesting to me because my approach is usually to let the networks figure everything out (especially w.r.t. rotation) -- but clearly in this competition that simply wasn't feasible.\r\n\r\nOne thing I'm curious about is what the resulting top-k accuracy looks like. Cross-entropy is always a bit difficult to interpret, and top-10 accuracy might be more indicative of the practical applicability of the approach. It would be great if the competition organisers could share some numbers on this, like the organisers of the National Data Science Bowl did last year ( https://www.kaggle.com/c/datasciencebowl/forums/t/12995/classification-accuracy-in-top-10-teams ).\r\n\r\nCongratulations!",
      "votes": null
    },
    {
      "id": "105597",
      "postDate": "01/25/2016 03:07:45",
      "content": "<p>Is the code ready?</p>",
      "rawMarkdown": "Is the code ready?",
      "votes": null
    },
    {
      "id": "105598",
      "postDate": "01/25/2016 03:09:02",
      "content": "<p>We're working on it ;)</p>",
      "rawMarkdown": "We're working on it ;)",
      "votes": null
    },
    {
      "id": "105750",
      "postDate": "01/26/2016 14:28:12",
      "content": "<p>Brawo, gratulacje! W&#322;a&#347;nie wyczyta&#322;em w popularnej prasie o waszym zwyci&#281;stwie.</p>",
      "rawMarkdown": "Brawo, gratulacje! Właśnie wyczytałem w popularnej prasie o waszym zwycięstwie.",
      "votes": null
    },
    {
      "id": "109362",
      "postDate": "02/25/2016 14:05:30",
      "content": "<p>How exactly the &quot;quantizing the output into bins and using Softmax&quot; part works?</p>",
      "rawMarkdown": "How exactly the \"quantizing the output into bins and using Softmax\" part works?",
      "votes": null
    },
    {
      "id": "109698",
      "postDate": "02/29/2016 16:06:02",
      "content": "<p>Instead of producing a real number in [0; 256] you can divide this interval into, say, 20 different bins. The first one would be [0; 256 / 20), the second one [256 / 20, 2 * 256 / 20), and so on. Having these disjoint intervals, you can treat the problem as a multicass classification - instead of predicting the coordinate accurately, you just determine some range that it falls into (i.e. one of the bins). When using a neural network, adding a Softmax layer, and using cross-entropy loss would be the way to go.</p>",
      "rawMarkdown": "Instead of producing a real number in [0; 256] you can divide this interval into, say, 20 different bins. The first one would be [0; 256 / 20), the second one [256 / 20, 2 * 256 / 20), and so on. Having these disjoint intervals, you can treat the problem as a multicass classification - instead of predicting the coordinate accurately, you just determine some range that it falls into (i.e. one of the bins). When using a neural network, adding a Softmax layer, and using cross-entropy loss would be the way to go.",
      "votes": null
    },
    {
      "id": "119033",
      "postDate": "05/06/2016 19:48:55",
      "content": "<p>Thank you for this post. What is the accuracy of this model?</p>",
      "rawMarkdown": "Thank you for this post. What is the accuracy of this model?",
      "votes": null
    },
    {
      "id": "119376",
      "postDate": "05/09/2016 16:31:12",
      "content": "<p>87%</p>",
      "rawMarkdown": "87%",
      "votes": null
    },
    {
      "id": "161580",
      "postDate": "02/14/2017 16:25:06",
      "content": "<p>Can you please provide the final code for us to learn from it ??</p>",
      "rawMarkdown": "Can you please provide the final code for us to learn from it ??",
      "votes": null
    },
    {
      "id": "161582",
      "postDate": "02/14/2017 16:35:21",
      "content": "<p>Here's a blog post outlining the approach by Deepsense.io: </p>\n\n<p><a href=\"http://deepsense.io/deep-learning-right-whale-recognition-kaggle/\">http://deepsense.io/deep-learning-right-whale-recognition-kaggle/</a>.</p>\n\n<p>Source code (and some trained models) can be found at:</p>\n\n<p><a href=\"https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1\">https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1</a>.</p>",
      "rawMarkdown": "Here's a blog post outlining the approach by Deepsense.io: \n\nhttp://deepsense.io/deep-learning-right-whale-recognition-kaggle/.\n\nSource code (and some trained models) can be found at:\n\nhttps://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1.",
      "votes": null
    },
    {
      "id": "161598",
      "postDate": "02/14/2017 19:39:00",
      "content": "<p>ok thanks. I believe this is the final code in working condition.</p>",
      "rawMarkdown": "ok thanks. I believe this is the final code in working condition.",
      "votes": null
    },
    {
      "id": "162149",
      "postDate": "02/17/2017 12:19:47",
      "content": "<p>Hi, anyone tried to run the code provided by the DeepSense team, please? I am getting the following error, can anyone help ?  thank you very much.</p>\n\n<p><em><strong>//error call stack</strong></em></p>\n\n<p>Traceback (most recent call last): <br>\nFile \"/media/samihaq/Quest2/deepsense-whales/whales/dataloading.py\", line 425, in fetch_example_anno_indygo\n img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w)) <br>\nFile \"/media/samihaq/Quest2/deepsense-whales/augmentation.py\", line 108, in fast_warp\n    m = tf._matrix AttributeError: 'AffineTransform' object has no attribute '_matrix'</p>\n\n<p>///////////////////////////////////////////////////////////////////////////\nAffineTransform class is from \"scikit-image\" and indeed it does not have any member \"_matrix\" but the code provided by DeepSense team refers to that.</p>\n\n<p><em><strong>// function call</strong></em></p>\n\n<pre><code>img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w)) \n</code></pre>\n\n<p><em><strong>// function</strong></em></p>\n\n<pre><code>def fast_warp(img, tf, output_shape=(50, 50), mode='constant', order=1):\n    \"\"\"\n    This wrapper function is faster than skimage.transform.warp\n    \"\"\"\n    m = tf._matrix\n    res = np.zeros(shape=(output_shape[0], output_shape[1], 3), dtype=floatX)\n    from scipy.ndimage import affine_transform\n    trans, offset = m[:2, :2], (m[0, 2], m[1, 2])\n    res[:, :, 0] = affine_transform(img[:, :, 0].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n    res[:, :, 1] = affine_transform(img[:, :, 1].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n    res[:, :, 2] = affine_transform(img[:, :, 2].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n    return res\n</code></pre>\n\n<p>Regards</p>",
      "rawMarkdown": "Hi, anyone tried to run the code provided by the DeepSense team, please? I am getting the following error, can anyone help ?  thank you very much.\n\n***//error call stack***\n\nTraceback (most recent call last):   \nFile \"/media/samihaq/Quest2/deepsense-whales/whales/dataloading.py\", line 425, in fetch_example_anno_indygo\n img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w))   \nFile \"/media/samihaq/Quest2/deepsense-whales/augmentation.py\", line 108, in fast_warp\n    m = tf._matrix AttributeError: 'AffineTransform' object has no attribute '_matrix'\n\n///////////////////////////////////////////////////////////////////////////\nAffineTransform class is from \"scikit-image\" and indeed it does not have any member \"_matrix\" but the code provided by DeepSense team refers to that.\n\n***// function call***\n\n    img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w)) \n\n \n***// function***\n\n    def fast_warp(img, tf, output_shape=(50, 50), mode='constant', order=1):\n        \"\"\"\n        This wrapper function is faster than skimage.transform.warp\n        \"\"\"\n        m = tf._matrix\n        res = np.zeros(shape=(output_shape[0], output_shape[1], 3), dtype=floatX)\n        from scipy.ndimage import affine_transform\n        trans, offset = m[:2, :2], (m[0, 2], m[1, 2])\n        res[:, :, 0] = affine_transform(img[:, :, 0].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n        res[:, :, 1] = affine_transform(img[:, :, 1].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n        res[:, :, 2] = affine_transform(img[:, :, 2].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n        return res\n\n\nRegards",
      "votes": null
    },
    {
      "id": "162625",
      "postDate": "02/20/2017 11:11:28",
      "content": "<p>Hi,\nMaciek from deepsense team here. You are right. I think _matrix was deprecated in the version we used and was finally removed(<a href=\"https://github.com/scikit-image/scikit-image/blob/e38ed91c248b9b84474234d2a8231ab36122bbc5/skimage/transform/_geometric.py#L125\">https://github.com/scikit-image/scikit-image/blob/e38ed91c248b9b84474234d2a8231ab36122bbc5/skimage/transform/_geometric.py#L125</a>). You can use params instead or _matrix or use older version of scikit-image which supports _matrix.</p>",
      "rawMarkdown": "Hi,\nMaciek from deepsense team here. You are right. I think _matrix was deprecated in the version we used and was finally removed(https://github.com/scikit-image/scikit-image/blob/e38ed91c248b9b84474234d2a8231ab36122bbc5/skimage/transform/_geometric.py#L125). You can use params instead or _matrix or use older version of scikit-image which supports _matrix.",
      "votes": null
    },
    {
      "id": "162881",
      "postDate": "02/21/2017 16:53:51",
      "content": "<p>@maciejk. Thank you. It worked.</p>",
      "rawMarkdown": "maciejk. Thank you. It worked.",
      "votes": null
    },
    {
      "id": "162884",
      "postDate": "02/21/2017 17:21:10",
      "content": "<p>Thanks, it worked.</p>",
      "rawMarkdown": "Thanks, it worked.",
      "votes": null
    },
    {
      "id": "170541",
      "postDate": "03/26/2017 10:28:38",
      "content": "<p>Hi, thanks for your sharing.\nI would like to try your model as pre trained model in Keras. However, I don't know how to load and open your model which is in 3c format. Could anyone help? Thanks a lot!</p>",
      "rawMarkdown": "Hi, thanks for your sharing.\nI would like to try your model as pre trained model in Keras. However, I don't know how to load and open your model which is in 3c format. Could anyone help? Thanks a lot!",
      "votes": null
    },
    {
      "id": "864088",
      "postDate": "05/27/2020 19:24:58",
      "content": "<p>Hello,</p>\n\n<p>I am trying to run your solution. I was hoping you could tell me what version of Theano you were using to allow this code to run? </p>\n\n<p>Thanks in advance.</p>",
      "rawMarkdown": "Hello,\n\nI am trying to run your solution. I was hoping you could tell me what version of Theano you were using to allow this code to run? \n\nThanks in advance.",
      "votes": null
    },
    {
      "id": "1002465",
      "postDate": "09/08/2020 06:39:23",
      "content": "<p>Looks like the website name changed. Here's the new one: <a href=\"https://deepsense.ai/deep-learning-right-whale-recognition-kaggle/\" target=\"_blank\">https://deepsense.ai/deep-learning-right-whale-recognition-kaggle/</a></p>",
      "rawMarkdown": "Looks like the website name changed. Here's the new one: https://deepsense.ai/deep-learning-right-whale-recognition-kaggle/",
      "votes": null
    },
    {
      "id": "1394339",
      "postDate": "07/20/2021 10:04:20",
      "content": "<p>great! thank you for sharing!</p>",
      "rawMarkdown": "great! thank you for sharing!",
      "votes": null
    },
    {
      "id": "1394710",
      "postDate": "07/20/2021 14:41:31",
      "content": "<p><a href=\"https://conbio.onlinelibrary.wiley.com/doi/full/10.1111/cobi.13226?af=R\" target=\"_blank\">https://conbio.onlinelibrary.wiley.com/doi/full/10.1111/cobi.13226?af=R</a></p>",
      "rawMarkdown": "https://conbio.onlinelibrary.wiley.com/doi/full/10.1111/cobi.13226?af=R",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 1002465,
      "author_name": "robbynevels",
      "author_url": "",
      "post_date": "09/08/2020 06:39:23",
      "content": "<p>Looks like the website name changed. Here's the new one: <a href=\"https://deepsense.ai/deep-learning-right-whale-recognition-kaggle/\" target=\"_blank\">https://deepsense.ai/deep-learning-right-whale-recognition-kaggle/</a></p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1394339,
      "author_name": "faaizhashmi",
      "author_url": "",
      "post_date": "07/20/2021 10:04:20",
      "content": "<p>great! thank you for sharing!</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 1394710,
      "author_name": "cbkhan",
      "author_url": "",
      "post_date": "07/20/2021 14:41:31",
      "content": "<p><a href=\"https://conbio.onlinelibrary.wiley.com/doi/full/10.1111/cobi.13226?af=R\" target=\"_blank\">https://conbio.onlinelibrary.wiley.com/doi/full/10.1111/cobi.13226?af=R</a></p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 104789,
      "author_name": "mas313",
      "author_url": "",
      "post_date": "01/16/2016 16:26:13",
      "content": "<p>Congratulations and thanks for sharing. </p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 104868,
      "author_name": "sedielem",
      "author_url": "",
      "post_date": "01/17/2016 15:24:06",
      "content": "<p>Excellent work, and thanks for the detailed blog post! It demonstrates a very pragmatic attitude (i.e. cutting corners when you need to, but being well aware of it) that I think is essential to do well on Kaggle. The resulting model is especially interesting to me because my approach is usually to let the networks figure everything out (especially w.r.t. rotation) -- but clearly in this competition that simply wasn't feasible.</p>\n\n<p>One thing I'm curious about is what the resulting top-k accuracy looks like. Cross-entropy is always a bit difficult to interpret, and top-10 accuracy might be more indicative of the practical applicability of the approach. It would be great if the competition organisers could share some numbers on this, like the organisers of the National Data Science Bowl did last year ( <a href=\"https://www.kaggle.com/c/datasciencebowl/forums/t/12995/classification-accuracy-in-top-10-teams\">https://www.kaggle.com/c/datasciencebowl/forums/t/12995/classification-accuracy-in-top-10-teams</a> ).</p>\n\n<p>Congratulations!</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 105597,
      "author_name": "pipipopo",
      "author_url": "",
      "post_date": "01/25/2016 03:07:45",
      "content": "<p>Is the code ready?</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 105598,
      "author_name": "robibok",
      "author_url": "",
      "post_date": "01/25/2016 03:09:02",
      "content": "<p>We're working on it ;)</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 105750,
      "author_name": "wojciechmigda",
      "author_url": "",
      "post_date": "01/26/2016 14:28:12",
      "content": "<p>Brawo, gratulacje! W&#322;a&#347;nie wyczyta&#322;em w popularnej prasie o waszym zwyci&#281;stwie.</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 109362,
      "author_name": "pedromnasc",
      "author_url": "",
      "post_date": "02/25/2016 14:05:30",
      "content": "<p>How exactly the &quot;quantizing the output into bins and using Softmax&quot; part works?</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 109698,
      "author_name": "robibok",
      "author_url": "",
      "post_date": "02/29/2016 16:06:02",
      "content": "<p>Instead of producing a real number in [0; 256] you can divide this interval into, say, 20 different bins. The first one would be [0; 256 / 20), the second one [256 / 20, 2 * 256 / 20), and so on. Having these disjoint intervals, you can treat the problem as a multicass classification - instead of predicting the coordinate accurately, you just determine some range that it falls into (i.e. one of the bins). When using a neural network, adding a Softmax layer, and using cross-entropy loss would be the way to go.</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 119033,
      "author_name": "abdulwahabkabani",
      "author_url": "",
      "post_date": "05/06/2016 19:48:55",
      "content": "<p>Thank you for this post. What is the accuracy of this model?</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 119376,
      "author_name": "robibok",
      "author_url": "",
      "post_date": "05/09/2016 16:31:12",
      "content": "<p>87%</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 161580,
      "author_name": "samihaq",
      "author_url": "",
      "post_date": "02/14/2017 16:25:06",
      "content": "<p>Can you please provide the final code for us to learn from it ??</p>",
      "votes": null,
      "replies": [
        {
          "id": 161582,
          "author_name": "cbkhan",
          "author_url": "",
          "post_date": "02/14/2017 16:35:21",
          "content": "<p>Here's a blog post outlining the approach by Deepsense.io: </p>\n\n<p><a href=\"http://deepsense.io/deep-learning-right-whale-recognition-kaggle/\">http://deepsense.io/deep-learning-right-whale-recognition-kaggle/</a>.</p>\n\n<p>Source code (and some trained models) can be found at:</p>\n\n<p><a href=\"https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1\">https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1</a>.</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 161598,
          "author_name": "samihaq",
          "author_url": "",
          "post_date": "02/14/2017 19:39:00",
          "content": "<p>ok thanks. I believe this is the final code in working condition.</p>",
          "votes": null,
          "replies": []
        }
      ]
    },
    {
      "id": 162149,
      "author_name": "samihaq",
      "author_url": "",
      "post_date": "02/17/2017 12:19:47",
      "content": "<p>Hi, anyone tried to run the code provided by the DeepSense team, please? I am getting the following error, can anyone help ?  thank you very much.</p>\n\n<p><em><strong>//error call stack</strong></em></p>\n\n<p>Traceback (most recent call last): <br>\nFile \"/media/samihaq/Quest2/deepsense-whales/whales/dataloading.py\", line 425, in fetch_example_anno_indygo\n img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w)) <br>\nFile \"/media/samihaq/Quest2/deepsense-whales/augmentation.py\", line 108, in fast_warp\n    m = tf._matrix AttributeError: 'AffineTransform' object has no attribute '_matrix'</p>\n\n<p>///////////////////////////////////////////////////////////////////////////\nAffineTransform class is from \"scikit-image\" and indeed it does not have any member \"_matrix\" but the code provided by DeepSense team refers to that.</p>\n\n<p><em><strong>// function call</strong></em></p>\n\n<pre><code>img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w)) \n</code></pre>\n\n<p><em><strong>// function</strong></em></p>\n\n<pre><code>def fast_warp(img, tf, output_shape=(50, 50), mode='constant', order=1):\n    \"\"\"\n    This wrapper function is faster than skimage.transform.warp\n    \"\"\"\n    m = tf._matrix\n    res = np.zeros(shape=(output_shape[0], output_shape[1], 3), dtype=floatX)\n    from scipy.ndimage import affine_transform\n    trans, offset = m[:2, :2], (m[0, 2], m[1, 2])\n    res[:, :, 0] = affine_transform(img[:, :, 0].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n    res[:, :, 1] = affine_transform(img[:, :, 1].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n    res[:, :, 2] = affine_transform(img[:, :, 2].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n    return res\n</code></pre>\n\n<p>Regards</p>",
      "votes": null,
      "replies": [
        {
          "id": 162625,
          "author_name": "maciejk",
          "author_url": "",
          "post_date": "02/20/2017 11:11:28",
          "content": "<p>Hi,\nMaciek from deepsense team here. You are right. I think _matrix was deprecated in the version we used and was finally removed(<a href=\"https://github.com/scikit-image/scikit-image/blob/e38ed91c248b9b84474234d2a8231ab36122bbc5/skimage/transform/_geometric.py#L125\">https://github.com/scikit-image/scikit-image/blob/e38ed91c248b9b84474234d2a8231ab36122bbc5/skimage/transform/_geometric.py#L125</a>). You can use params instead or _matrix or use older version of scikit-image which supports _matrix.</p>",
          "votes": null,
          "replies": []
        },
        {
          "id": 162884,
          "author_name": "samihaq",
          "author_url": "",
          "post_date": "02/21/2017 17:21:10",
          "content": "<p>Thanks, it worked.</p>",
          "votes": null,
          "replies": []
        }
      ]
    },
    {
      "id": 162881,
      "author_name": "samihaq",
      "author_url": "",
      "post_date": "02/21/2017 16:53:51",
      "content": "<p>@maciejk. Thank you. It worked.</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 170541,
      "author_name": "chentung",
      "author_url": "",
      "post_date": "03/26/2017 10:28:38",
      "content": "<p>Hi, thanks for your sharing.\nI would like to try your model as pre trained model in Keras. However, I don't know how to load and open your model which is in 3c format. Could anyone help? Thanks a lot!</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 864088,
      "author_name": "joshuapower",
      "author_url": "",
      "post_date": "05/27/2020 19:24:58",
      "content": "<p>Hello,</p>\n\n<p>I am trying to run your solution. I was hoping you could tell me what version of Theano you were using to allow this code to run? </p>\n\n<p>Thanks in advance.</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "104784": "Here's a blog post outlining our approach: http://deepsense.io/deep-learning-right-whale-recognition-kaggle/.\r\n\r\nSource code (and some trained models) can be found at https://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1.",
    "104789": "Congratulations and thanks for sharing.",
    "104868": "Excellent work, and thanks for the detailed blog post! It demonstrates a very pragmatic attitude (i.e. cutting corners when you need to, but being well aware of it) that I think is essential to do well on Kaggle. The resulting model is especially interesting to me because my approach is usually to let the networks figure everything out (especially w.r.t. rotation) -- but clearly in this competition that simply wasn't feasible.\r\n\r\nOne thing I'm curious about is what the resulting top-k accuracy looks like. Cross-entropy is always a bit difficult to interpret, and top-10 accuracy might be more indicative of the practical applicability of the approach. It would be great if the competition organisers could share some numbers on this, like the organisers of the National Data Science Bowl did last year ( https://www.kaggle.com/c/datasciencebowl/forums/t/12995/classification-accuracy-in-top-10-teams ).\r\n\r\nCongratulations!",
    "105597": "Is the code ready?",
    "105598": "We're working on it ;)",
    "105750": "Brawo, gratulacje! Właśnie wyczytałem w popularnej prasie o waszym zwycięstwie.",
    "109362": "How exactly the \"quantizing the output into bins and using Softmax\" part works?",
    "109698": "Instead of producing a real number in [0; 256] you can divide this interval into, say, 20 different bins. The first one would be [0; 256 / 20), the second one [256 / 20, 2 * 256 / 20), and so on. Having these disjoint intervals, you can treat the problem as a multicass classification - instead of predicting the coordinate accurately, you just determine some range that it falls into (i.e. one of the bins). When using a neural network, adding a Softmax layer, and using cross-entropy loss would be the way to go.",
    "119033": "Thank you for this post. What is the accuracy of this model?",
    "119376": "87%",
    "161580": "Can you please provide the final code for us to learn from it ??",
    "161582": "Here's a blog post outlining the approach by Deepsense.io: \n\nhttp://deepsense.io/deep-learning-right-whale-recognition-kaggle/.\n\nSource code (and some trained models) can be found at:\n\nhttps://www.dropbox.com/s/rohrc1btslxwxzr/deepsense-whales.zip?dl=1.",
    "161598": "ok thanks. I believe this is the final code in working condition.",
    "162149": "Hi, anyone tried to run the code provided by the DeepSense team, please? I am getting the following error, can anyone help ?  thank you very much.\n\n***//error call stack***\n\nTraceback (most recent call last):   \nFile \"/media/samihaq/Quest2/deepsense-whales/whales/dataloading.py\", line 425, in fetch_example_anno_indygo\n img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w))   \nFile \"/media/samihaq/Quest2/deepsense-whales/augmentation.py\", line 108, in fast_warp\n    m = tf._matrix AttributeError: 'AffineTransform' object has no attribute '_matrix'\n\n///////////////////////////////////////////////////////////////////////////\nAffineTransform class is from \"scikit-image\" and indeed it does not have any member \"_matrix\" but the code provided by DeepSense team refers to that.\n\n***// function call***\n\n    img = fast_warp(img, AffineTransform(tform_res._inv_matrix), output_shape=(target_h, target_w)) \n\n \n***// function***\n\n    def fast_warp(img, tf, output_shape=(50, 50), mode='constant', order=1):\n        \"\"\"\n        This wrapper function is faster than skimage.transform.warp\n        \"\"\"\n        m = tf._matrix\n        res = np.zeros(shape=(output_shape[0], output_shape[1], 3), dtype=floatX)\n        from scipy.ndimage import affine_transform\n        trans, offset = m[:2, :2], (m[0, 2], m[1, 2])\n        res[:, :, 0] = affine_transform(img[:, :, 0].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n        res[:, :, 1] = affine_transform(img[:, :, 1].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n        res[:, :, 2] = affine_transform(img[:, :, 2].T, trans, offset=offset, output_shape=output_shape, mode=mode, order=order)\n        return res\n\n\nRegards",
    "162625": "Hi,\nMaciek from deepsense team here. You are right. I think _matrix was deprecated in the version we used and was finally removed(https://github.com/scikit-image/scikit-image/blob/e38ed91c248b9b84474234d2a8231ab36122bbc5/skimage/transform/_geometric.py#L125). You can use params instead or _matrix or use older version of scikit-image which supports _matrix.",
    "162881": "maciejk. Thank you. It worked.",
    "162884": "Thanks, it worked.",
    "170541": "Hi, thanks for your sharing.\nI would like to try your model as pre trained model in Keras. However, I don't know how to load and open your model which is in 3c format. Could anyone help? Thanks a lot!",
    "864088": "Hello,\n\nI am trying to run your solution. I was hoping you could tell me what version of Theano you were using to allow this code to run? \n\nThanks in advance.",
    "1002465": "Looks like the website name changed. Here's the new one: https://deepsense.ai/deep-learning-right-whale-recognition-kaggle/",
    "1394339": "great! thank you for sharing!",
    "1394710": "https://conbio.onlinelibrary.wiley.com/doi/full/10.1111/cobi.13226?af=R"
  },
  "source": "meta"
}