{
  "id": 140866,
  "title": "[placeholder] external data and how to use them",
  "url": "/competitions/flower-classification-with-tpus/discussion/140866",
  "author_name": "hengck23",
  "post_date": "2020-04-03T13:50:49.884000",
  "votes": 23,
  "comment_count": 33,
  "views": 0,
  "content": "<h2>[update and important! on may-07]</h2>\n\n<p>please see  <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329</a>\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"</p>\n\n<p>in summary, using external labels of \"test images or their duplicates in external data\" is not allowed!</p>\n\n<hr>\n\n<p>this thread will be constantly update as i download more data.\nother kaggler are welcome to contribute. see also this thread for use of external data: <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/134701\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/134701</a></p>\n\n<p>google drive: \n<a href=\"https://drive.google.com/open?id=1yOZjOY3z7Dtki9KRpNxQK6FTO7Uq3IhL\">https://drive.google.com/open?id=1yOZjOY3z7Dtki9KRpNxQK6FTO7Uq3IhL</a></p>\n\n<p>kaggle dataset\n<a href=\"https://www.kaggle.com/hengck23/externaldatasettpuflower\">https://www.kaggle.com/hengck23/externaldatasettpuflower</a></p>\n\n<hr>\n\n<p>for imagenet:\n- please refer to \"download_code\" to see how you can download your own file\n- see also : <a href=\"https://medium.com/coinmonks/how-to-get-images-from-imagenet-with-python-in-google-colaboratory-aeef5c1c45e5\">https://medium.com/coinmonks/how-to-get-images-from-imagenet-with-python-in-google-colaboratory-aeef5c1c45e5</a></p>\n\n<hr>\n\n<p>we are still working on this this but here is how we setup the problem for this challenge:</p>\n\n<p>1)dataset: \n- kaggle train (labelled) and test (unlabelled)\n- external data (labelled but using different labeling)\n   - Conversion to kaggle label is sometime unknown. Some external label may not even present in kaggle label \n   - some label in external data are incorrect. Some images are just noisy image (e.g. just contains leaves and no flower,)</p>\n\n<p>2)learning and loss\n- cross entropy for kaggle train data\n- some novel loss for external data to take care of unknown mapping and label noise</p>",
  "messages": [
    {
      "id": 796326,
      "postDate": "2020-04-03T13:50:49.883Z",
      "content": "<h2>[update and important! on may-07]</h2>\n\n<p>please see  <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329</a>\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"</p>\n\n<p>in summary, using external labels of \"test images or their duplicates in external data\" is not allowed!</p>\n\n<hr>\n\n<p>this thread will be constantly update as i download more data.\nother kaggler are welcome to contribute. see also this thread for use of external data: <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/134701\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/134701</a></p>\n\n<p>google drive: \n<a href=\"https://drive.google.com/open?id=1yOZjOY3z7Dtki9KRpNxQK6FTO7Uq3IhL\">https://drive.google.com/open?id=1yOZjOY3z7Dtki9KRpNxQK6FTO7Uq3IhL</a></p>\n\n<p>kaggle dataset\n<a href=\"https://www.kaggle.com/hengck23/externaldatasettpuflower\">https://www.kaggle.com/hengck23/externaldatasettpuflower</a></p>\n\n<hr>\n\n<p>for imagenet:\n- please refer to \"download_code\" to see how you can download your own file\n- see also : <a href=\"https://medium.com/coinmonks/how-to-get-images-from-imagenet-with-python-in-google-colaboratory-aeef5c1c45e5\">https://medium.com/coinmonks/how-to-get-images-from-imagenet-with-python-in-google-colaboratory-aeef5c1c45e5</a></p>\n\n<hr>\n\n<p>we are still working on this this but here is how we setup the problem for this challenge:</p>\n\n<p>1)dataset: \n- kaggle train (labelled) and test (unlabelled)\n- external data (labelled but using different labeling)\n   - Conversion to kaggle label is sometime unknown. Some external label may not even present in kaggle label \n   - some label in external data are incorrect. Some images are just noisy image (e.g. just contains leaves and no flower,)</p>\n\n<p>2)learning and loss\n- cross entropy for kaggle train data\n- some novel loss for external data to take care of unknown mapping and label noise</p>",
      "rawMarkdown": "##[update and important! on may-07]##\nplease see  https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"\n\nin summary, using external labels of \"test images or their duplicates in external data\" is not allowed!\n\n----\nthis thread will be constantly update as i download more data.\nother kaggler are welcome to contribute. see also this thread for use of external data: https://www.kaggle.com/c/flower-classification-with-tpus/discussion/134701\n\ngoogle drive: \nhttps://drive.google.com/open?id=1yOZjOY3z7Dtki9KRpNxQK6FTO7Uq3IhL\n\nkaggle dataset\nhttps://www.kaggle.com/hengck23/externaldatasettpuflower\n \n\n---\n\nfor imagenet:\n- please refer to \"download\\_code\" to see how you can download your own file\n- see also : https://medium.com/coinmonks/how-to-get-images-from-imagenet-with-python-in-google-colaboratory-aeef5c1c45e5\n\n---\n\nwe are still working on this this but here is how we setup the problem for this challenge:\n\n1)dataset: \n- kaggle train (labelled) and test (unlabelled)\n- external data (labelled but using different labeling)\n   - Conversion to kaggle label is sometime unknown. Some external label may not even present in kaggle label \n   - some label in external data are incorrect. Some images are just noisy image (e.g. just contains leaves and no flower,)\n\n2)learning and loss\n- cross entropy for kaggle train data\n- some novel loss for external data to take care of unknown mapping and label noise\n",
      "votes": 23
    },
    {
      "id": 816698,
      "postDate": "2020-04-22T14:20:36.470Z",
      "content": "<p>Hi Heng CherKeng, thanks for sharing.  I have converted your dataset to tfrecords (just for convenience).\n<a href=\"https://www.kaggle.com/kirillblinov/tf-flower-photo-tfrec\">https://www.kaggle.com/kirillblinov/tf-flower-photo-tfrec</a></p>",
      "rawMarkdown": "Hi Heng CherKeng, thanks for sharing.  I have converted your dataset to tfrecords (just for convenience).\nhttps://www.kaggle.com/kirillblinov/tf-flower-photo-tfrec\n",
      "votes": 10,
      "replies": [
        {
          "id": 817490,
          "postDate": "2020-04-23T07:42:33.977Z",
          "content": "<p>Thank you for sharing\ni using your dataset</p>",
          "rawMarkdown": "Thank you for sharing\ni using your dataset"
        },
        {
          "id": 820335,
          "postDate": "2020-04-25T10:51:04.360Z",
          "content": "<p><a href=\"/kirillblinov\">@kirillblinov</a> How did you convert the dataset? \nI also converted Heng's dataset using the label mapping he provided in comments but the size of dataset is much different from yours.\nYou can find my dataset here(<a href=\"https://www.kaggle.com/gaur128/externaldatasettpuflowers\">https://www.kaggle.com/gaur128/externaldatasettpuflowers</a>).</p>\n\n<p>P.S Thank you for sharing, it is a lot better than mine.</p>",
          "rawMarkdown": "@kirillblinov How did you convert the dataset? \nI also converted Heng's dataset using the label mapping he provided in comments but the size of dataset is much different from yours.\nYou can find my dataset here(https://www.kaggle.com/gaur128/externaldatasettpuflowers).\n\nP.S Thank you for sharing, it is a lot better than mine."
        },
        {
          "id": 821758,
          "postDate": "2020-04-26T11:56:26.593Z",
          "content": "<p>Hi Gaurav Yadav, \nI have removed duplicated images using consecutively phash and dhash from <a href=\"https://pypi.org/project/ImageHash/\">ImageHash</a> library.  Structural Similarity Index works even better but requires much more time.</p>",
          "rawMarkdown": "Hi Gaurav Yadav, \nI have removed duplicated images using consecutively phash and dhash from [ImageHash](https://pypi.org/project/ImageHash/) library.  Structural Similarity Index works even better but requires much more time."
        },
        {
          "id": 821760,
          "postDate": "2020-04-26T11:57:58.537Z",
          "content": "<p>Hi BNK, you are welcome!</p>",
          "rawMarkdown": "Hi BNK, you are welcome!"
        },
        {
          "id": 821829,
          "postDate": "2020-04-26T12:55:38.443Z",
          "content": "<p><a href=\"/kirillblinov\">@kirillblinov</a> Is it in any way possible for you to share your dataset creation code maybe after the competition over.\nAnd once again thanks for sharing your dataset, it helped a lot.</p>",
          "rawMarkdown": "@kirillblinov Is it in any way possible for you to share your dataset creation code maybe after the competition over.\nAnd once again thanks for sharing your dataset, it helped a lot."
        },
        {
          "id": 826143,
          "postDate": "2020-04-29T13:28:04.120Z",
          "content": "<p>Hi Gaurav Yadav, I put some (most important part) code here:\n<a href=\"https://www.kaggle.com/kirillblinov/prepare-dataset\">https://www.kaggle.com/kirillblinov/prepare-dataset</a></p>",
          "rawMarkdown": "Hi Gaurav Yadav, I put some (most important part) code here:\nhttps://www.kaggle.com/kirillblinov/prepare-dataset",
          "votes": 1
        },
        {
          "id": 828988,
          "postDate": "2020-05-01T12:27:54.207Z",
          "content": "<p><a href=\"/kirillblinov\">@kirillblinov</a> Thanks a lot.</p>",
          "rawMarkdown": "@kirillblinov Thanks a lot."
        }
      ]
    },
    {
      "id": 809094,
      "postDate": "2020-04-15T21:05:33.607Z",
      "content": "<p>Here is a set of tfrecords for the openimage images included in <a href=\"/hengck23\">@hengck23</a> 's <a href=\"https://www.kaggle.com/hengck23/externaldatasettpuflower.\">dataset</a>.</p>\n\n<p><a href=\"https://www.kaggle.com/calebeverett/flowers-tpu-openimage-tfrecords\">https://www.kaggle.com/calebeverett/flowers-tpu-openimage-tfrecords</a></p>\n\n<p>I separated the roses into a separate set of records since there were so many of them. It may make sense to sample them at a lower weight.</p>",
      "rawMarkdown": "Here is a set of tfrecords for the openimage images included in @hengck23 's [dataset](https://www.kaggle.com/hengck23/externaldatasettpuflower.).\n\nhttps://www.kaggle.com/calebeverett/flowers-tpu-openimage-tfrecords\n\nI separated the roses into a separate set of records since there were so many of them. It may make sense to sample them at a lower weight.",
      "votes": 3
    },
    {
      "id": 798499,
      "postDate": "2020-04-05T14:51:54.637Z",
      "content": "<p>reference results</p>\n\n<p>```\n224x244 for kaggle data\ncenter crop and resize to 224x224 for external data</p>\n\n<p>model = se-resnex50\nsingle fold: TTA = null + flip + scale</p>\n\n<p>LB= 0.93963  (local cv on val = 0.944625) <br>\n         for  training set = train  </p>\n\n<p>LB= 0.94683 <br>\n         for  training set =  train + val</p>\n\n<p>LB= 0.95224  (local cv on val = 0.958245) <br>\n         for  training set =  train + external (oxford+tf_flower, possibly overlap with val)</p>\n\n<p>LB= 0.95788 <br>\n         for  training set = train + val + external (oxford+tf_flower, possibly overlap with val)</p>\n\n<p>LB=  0.97507 (local cv on val = 0.983) <br>\n         for  training set = train  + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)</p>\n\n<p>LB= 0.97640\n         for  training set = train  + val + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)\n```</p>",
      "rawMarkdown": "reference results\n\n```\n224x244 for kaggle data\ncenter crop and resize to 224x224 for external data\n\nmodel = se-resnex50\nsingle fold: TTA = null + flip + scale\n\n\n LB= 0.93963  (local cv on val = 0.944625)   \n         for  training set = train  \n\n LB= 0.94683                                                                             \n         for  training set =  train + val\n\n LB= 0.95224  (local cv on val = 0.958245)                             \n         for  training set =  train + external (oxford+tf_flower, possibly overlap with val)\n\n LB= 0.95788                                                                              \n         for  training set = train + val + external (oxford+tf_flower, possibly overlap with val)\n\nLB=  0.97507 (local cv on val = 0.983)   \n         for  training set = train  + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)\n\n\nLB= 0.97640\n         for  training set = train  + val + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)\n```",
      "votes": 4,
      "replies": [
        {
          "id": 811297,
          "postDate": "2020-04-17T18:46:38.153Z",
          "content": "<p>Thank you for sharing!\nDo you use Torch or Keras for se-resnext50?</p>",
          "rawMarkdown": "Thank you for sharing!\nDo you use Torch or Keras for se-resnext50?"
        }
      ]
    },
    {
      "id": 836440,
      "postDate": "2020-05-07T01:58:50.927Z",
      "content": "<h2>[update and important! on may-07]</h2>\n\n<p>please see  <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329</a>\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"</p>\n\n<p>in summary, using external labels of \"test images or their duplicates in external data\" is not allowed!</p>",
      "rawMarkdown": "##[update and important! on may-07]##\n\nplease see  https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"\n\nin summary, using external labels of \"test images or their duplicates in external data\" is not allowed!\n",
      "votes": 1,
      "replies": [
        {
          "id": 836443,
          "postDate": "2020-05-07T02:04:11.667Z",
          "content": "<p>i haven't do a thorough and careful check. so far here are the duplicates i found. kaggler are free to contribute or double check, etc</p>",
          "rawMarkdown": "i haven't do a thorough and careful check. so far here are the duplicates i found. kaggler are free to contribute or double check, etc"
        },
        {
          "id": 836447,
          "postDate": "2020-05-07T02:10:39.087Z",
          "content": "<p>you can easily find the duplicate images by i) cropping images to square in external data, ii) resizing the external and kaggle images to small size (e.g. 20x20 or 16x16) iii) count the number of pixel difference as image similarity measure</p>\n\n<p>the attached code is an example</p>\n\n<p>the missing function in the attch code is:</p>\n\n<p>```</p>\n\n<p>def do_center_crop(image, size=192):\n    if (size,size)!=image.shape[:2]:\n        h,w = image.shape[:2]\n        s = min(h,w)\n        x = int(((w-s)/2))\n        y = int(((h-s)/2))\n        image = image[y:y+s, x:x+s]\n        image = cv2.resize(image,dsize=(size,size),interpolation=cv2.INTER_LINEAR)\n    return image</p>\n\n<p>```</p>",
          "rawMarkdown": "you can easily find the duplicate images by i) cropping images to square in external data, ii) resizing the external and kaggle images to small size (e.g. 20x20 or 16x16) iii) count the number of pixel difference as image similarity measure\n\nthe attached code is an example\n\nthe missing function in the attch code is:\n\n```\n\ndef do_center_crop(image, size=192):\n    if (size,size)!=image.shape[:2]:\n        h,w = image.shape[:2]\n        s = min(h,w)\n        x = int(((w-s)/2))\n        y = int(((h-s)/2))\n        image = image[y:y+s, x:x+s]\n        image = cv2.resize(image,dsize=(size,size),interpolation=cv2.INTER_LINEAR)\n    return image\n\n\n```"
        },
        {
          "id": 836460,
          "postDate": "2020-05-07T02:24:16.410Z",
          "content": "<p>That's a nice quick method. Another way to find all the duplicates is by taking the output from a CNN final hidden layer and then using RAPIDS kNN to compare external data with test data. This finds all the duplicates.</p>",
          "rawMarkdown": "That's a nice quick method. Another way to find all the duplicates is by taking the output from a CNN final hidden layer and then using RAPIDS kNN to compare external data with test data. This finds all the duplicates."
        },
        {
          "id": 836628,
          "postDate": "2020-05-07T05:43:02.203Z",
          "rawMarkdown": "",
          "isDeleted": true
        },
        {
          "id": 836693,
          "postDate": "2020-05-07T06:47:50.043Z",
          "content": "<p>i don't think it matters.  but i do not represent kaggle. it is better you put the question in the official thread at: <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/130276\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/130276</a></p>",
          "rawMarkdown": "i don't think it matters.  but i do not represent kaggle. it is better you put the question in the official thread at: https://www.kaggle.com/c/flower-classification-with-tpus/discussion/130276"
        },
        {
          "id": 837725,
          "postDate": "2020-05-08T02:12:39.710Z",
          "rawMarkdown": "",
          "isDeleted": true
        },
        {
          "id": 837889,
          "postDate": "2020-05-08T05:45:00.533Z",
          "content": "<p>i think kaggle processes and crops the source image to kaggle square image in only one way.  it is just a simple square center crop, where size of square = min(width,height) of external source image</p>\n\n<p>you can check the original oxford images and the kaggle images. i don't think there are other sophisticated way (e.g. taking part of the source image). but i cannot be 100% sure. </p>\n\n<p>as long as there is \"no intention to cheat\" and you \"have tried your best way to filter of the test duplicates\", i think your solution would be reasonable and acceptable.</p>",
          "rawMarkdown": "i think kaggle processes and crops the source image to kaggle square image in only one way.  it is just a simple square center crop, where size of square = min(width,height) of external source image\n\nyou can check the original oxford images and the kaggle images. i don't think there are other sophisticated way (e.g. taking part of the source image). but i cannot be 100% sure. \n\nas long as there is \"no intention to cheat\" and you \"have tried your best way to filter of the test duplicates\", i think your solution would be reasonable and acceptable."
        },
        {
          "id": 837908,
          "postDate": "2020-05-08T06:20:58.230Z",
          "rawMarkdown": "",
          "isDeleted": true
        }
      ]
    },
    {
      "id": 796816,
      "postDate": "2020-04-04T00:22:10.927Z",
      "content": "<p>Hi Heng CherKeng, I downloaded the Oxford 102 Category Flower dataset and converted it into TFRecords for everyone in the Kaggle dataset <a href=\"https://www.kaggle.com/cdeotte/oxford-flowers-tfrecords\">here</a></p>",
      "rawMarkdown": "Hi Heng CherKeng, I downloaded the Oxford 102 Category Flower dataset and converted it into TFRecords for everyone in the Kaggle dataset [here][1]\n\n[1]: https://www.kaggle.com/cdeotte/oxford-flowers-tfrecords",
      "votes": 1,
      "replies": [
        {
          "id": 796912,
          "postDate": "2020-04-04T04:09:20.200Z",
          "content": "<p><a href=\"/cdeotte\">@cdeotte</a> </p>\n\n<p>thanks for the work and link.</p>\n\n<p>we are also using oxford flowers, and also tf flowers, imagenet-21k and inaturalist, JFT-300m</p>\n\n<p>both oxford flowers and tf flowers are very clean and our experiments show  about +0.006 improvement in public LB.</p>\n\n<p>the other external  dataset has much more significant noise and we are trying to see how to use them.</p>\n\n<hr>\n\n<p>you may also want to check the paper \"Big Transfer (BiT): General Visual Representation Learning\".\n<a href=\"https://paperswithcode.com/sota/fine-grained-image-classification-on-oxford\">https://paperswithcode.com/sota/fine-grained-image-classification-on-oxford</a>\nsee laso: <a href=\"https://github.com/Gogul09/flower-recognition\">https://github.com/Gogul09/flower-recognition</a></p>\n\n<p>JFT-300M pretrained model performs better than imagenet-1K for flower classification.</p>\n\n<p>instead of using external data like imagenet-21k, inaturalist, JFT-300m directly, one may use pretrained models trained on them (if you google, you can find a few of them ). one can use the features extracted from these pretrained models, in addition to the rgb pixel, as input to your CNN.</p>",
          "rawMarkdown": "@cdeotte \n\nthanks for the work and link.\n\nwe are also using oxford flowers, and also tf flowers, imagenet-21k and inaturalist, JFT-300m\n\nboth oxford flowers and tf flowers are very clean and our experiments show  about +0.006 improvement in public LB.\n\nthe other external  dataset has much more significant noise and we are trying to see how to use them.\n\n---\n\nyou may also want to check the paper \"Big Transfer (BiT): General Visual Representation Learning\".\nhttps://paperswithcode.com/sota/fine-grained-image-classification-on-oxford\nsee laso: https://github.com/Gogul09/flower-recognition\n\n\nJFT-300M pretrained model performs better than imagenet-1K for flower classification.\n\ninstead of using external data like imagenet-21k, inaturalist, JFT-300m directly, one may use pretrained models trained on them (if you google, you can find a few of them ). one can use the features extracted from these pretrained models, in addition to the rgb pixel, as input to your CNN.\n\n\n\n",
          "votes": 2
        },
        {
          "id": 810275,
          "postDate": "2020-04-16T20:33:04.430Z",
          "content": "<p>Here is the note on fixing the train-test resolution discrepancy referred to in the BiT paper. <a href=\"https://arxiv.org/pdf/2003.08237.pdf\">https://arxiv.org/pdf/2003.08237.pdf</a></p>",
          "rawMarkdown": "Here is the note on fixing the train-test resolution discrepancy referred to in the BiT paper. https://arxiv.org/pdf/2003.08237.pdf",
          "votes": 1
        }
      ]
    },
    {
      "id": 799100,
      "postDate": "2020-04-06T07:17:54.367Z",
      "content": "<p>this may seem to be good solution</p>\n\n<p>DivideMix: Learning with Noisy Labels as Semi-supervised Learning\n<a href=\"https://github.com/LiJunnan1992/DivideMix\">https://github.com/LiJunnan1992/DivideMix</a></p>\n\n<p>SELF: LEARNING TO FILTER NOISY LABELS WITH SELF-ENSEMBLING\n<a href=\"https://openreview.net/pdf?id=HkgsPhNYPS\">https://openreview.net/pdf?id=HkgsPhNYPS</a></p>\n\n<p>since external is noisy labelled, these methods may help to clean up</p>\n\n<p>others: <a href=\"https://github.com/subeeshvasu/Awesome-Learning-with-Label-Noise\">https://github.com/subeeshvasu/Awesome-Learning-with-Label-Noise</a></p>",
      "rawMarkdown": "this may seem to be good solution\n\nDivideMix: Learning with Noisy Labels as Semi-supervised Learning\nhttps://github.com/LiJunnan1992/DivideMix\n\nSELF: LEARNING TO FILTER NOISY LABELS WITH SELF-ENSEMBLING\nhttps://openreview.net/pdf?id=HkgsPhNYPS\n\n\nsince external is noisy labelled, these methods may help to clean up\n\nothers: https://github.com/subeeshvasu/Awesome-Learning-with-Label-Noise",
      "votes": 2
    },
    {
      "id": 798097,
      "postDate": "2020-04-05T07:09:49.827Z",
      "content": "<p>inaturalist-2107/18/19 dataset.\nsee also\n<a href=\"https://github.com/visipedia/inat_comp\">https://github.com/visipedia/inat_comp</a>\n<a href=\"https://www.inaturalist.org/pages/developers\">https://www.inaturalist.org/pages/developers</a></p>\n\n<p>Note: the mapping below is not 100% correct. (e.g. 'iris and yellow iris' are separate class in kaggle, but single class some inaturalist class). you may want to refine them yourselves. The inaturalist files can be downloaded from my google drive link above. </p>\n\n<p>there are duplicate in inaturalist-2107/18/19.\nit is probably better to download the images using url provided at \"<a href=\"https://www.inaturalist.org/pages/developers\">https://www.inaturalist.org/pages/developers</a>\".\nbut i haven't try it yet.</p>\n\n<p>inaturalist-2017 mapping:\n```\n   inaturalist_2017_map=np.array([\n        'Oenothera speciosa', 'pink primrose',\n        #'Verbena halei', 'pink primrose',  # '533c84731763d1230128406839bce6a5', 'fb3dab74d'\n        'Ranunculus acris', 'buttercup',\n        'Cirsium vulgare', 'spear thistle',\n        'Cirsium discolor', 'spear thistle',\n        'Ipomoea purpurea', 'morning glory',\n        #'Ricinus communis', 'morning glory', #'95bf31471ea018c3f768b493c93ea863', '0676ef538'\n        'Viola tricolor', 'wild pansy',\n        'Lilium parvum', 'tiger lily',\n        'Anemone nemorosa', 'windflower',\n        'Anemone quinquefolia', 'windflower',\n        'Gaura suffulta', 'gaura',\n    ]).reshape(-1,2)</p>\n\n<p>```</p>\n\n<p>inaturalist-2018 mapping:\n```\n    inaturalist_2018_map=np.array([\n        '6993', 'wild geranium',\n        '6996', 'wild geranium',\n        '6997', 'wild geranium',\n        '7448', 'pink primrose',\n        '5907', 'spear thistle',\n        '7673', 'wild rose',\n        '7674', 'wild rose',\n        '7676', 'wild rose',\n        '5267', 'tiger lily',\n        '5386', 'iris',  #or yellow iris\n        '5387', 'iris',\n        '5389', 'iris',\n        '5391', 'iris',\n    ]).reshape(-1,2)</p>\n\n<p>```</p>\n\n<p>inatutalist-2019 mapping\n<code>\n653 4 wild geranium\n654 4 wild geranium\n838 103 wild rose\n629 5 tiger lily\n773 0 pink primrose\n839 103 wild rose\n831 75 morning glory\n630 51 wild pansy\n835 103 wild rose\n962 67 iris\n954 67 iris\n494 5 tiger lily\n434 0 pink primrose\n960 67 iris\n955 67 iris\n841 103 wild rose\n360 13 spear thistle\n956 14 yellow iris\n651 4 wild geranium\n501 56 gaura\n961 67 iris\n650 4 wild geranium\n646 4 wild geranium\n492 0 pink primrose\n959 67 iris\n842 103 wild rose\n834 103 wild rose\n844 103 wild rose\n843 103 wild rose\n648 4 wild geranium\n655 4 wild geranium\n721 47 buttercup\n836 103 wild rose\n840 103 wild rose\n957 67 iris\n845 103 wild rose\n953 67 iris\n837 103 wild rose\n715 68 windflower\n958 67 iris\n722 47 buttercup\n</code></p>",
      "rawMarkdown": "inaturalist-2107/18/19 dataset.\nsee also\nhttps://github.com/visipedia/inat_comp\nhttps://www.inaturalist.org/pages/developers\n\n\nNote: the mapping below is not 100% correct. (e.g. 'iris and yellow iris' are separate class in kaggle, but single class some inaturalist class). you may want to refine them yourselves. The inaturalist files can be downloaded from my google drive link above. \n\n\nthere are duplicate in inaturalist-2107/18/19.\nit is probably better to download the images using url provided at \"https://www.inaturalist.org/pages/developers\".\nbut i haven't try it yet.\n\n\ninaturalist-2017 mapping:\n```\n   inaturalist_2017_map=np.array([\n        'Oenothera speciosa', 'pink primrose',\n        #'Verbena halei', 'pink primrose',  # '533c84731763d1230128406839bce6a5', 'fb3dab74d'\n        'Ranunculus acris', 'buttercup',\n        'Cirsium vulgare', 'spear thistle',\n        'Cirsium discolor', 'spear thistle',\n        'Ipomoea purpurea', 'morning glory',\n        #'Ricinus communis', 'morning glory', #'95bf31471ea018c3f768b493c93ea863', '0676ef538'\n        'Viola tricolor', 'wild pansy',\n        'Lilium parvum', 'tiger lily',\n        'Anemone nemorosa', 'windflower',\n        'Anemone quinquefolia', 'windflower',\n        'Gaura suffulta', 'gaura',\n    ]).reshape(-1,2)\n\n```\n\ninaturalist-2018 mapping:\n```\n    inaturalist_2018_map=np.array([\n        '6993', 'wild geranium',\n        '6996', 'wild geranium',\n        '6997', 'wild geranium',\n        '7448', 'pink primrose',\n        '5907', 'spear thistle',\n        '7673', 'wild rose',\n        '7674', 'wild rose',\n        '7676', 'wild rose',\n        '5267', 'tiger lily',\n        '5386', 'iris',  #or yellow iris\n        '5387', 'iris',\n        '5389', 'iris',\n        '5391', 'iris',\n    ]).reshape(-1,2)\n\n```\n\n\ninatutalist-2019 mapping\n```\n653 4 wild geranium\n654 4 wild geranium\n838 103 wild rose\n629 5 tiger lily\n773 0 pink primrose\n839 103 wild rose\n831 75 morning glory\n630 51 wild pansy\n835 103 wild rose\n962 67 iris\n954 67 iris\n494 5 tiger lily\n434 0 pink primrose\n960 67 iris\n955 67 iris\n841 103 wild rose\n360 13 spear thistle\n956 14 yellow iris\n651 4 wild geranium\n501 56 gaura\n961 67 iris\n650 4 wild geranium\n646 4 wild geranium\n492 0 pink primrose\n959 67 iris\n842 103 wild rose\n834 103 wild rose\n844 103 wild rose\n843 103 wild rose\n648 4 wild geranium\n655 4 wild geranium\n721 47 buttercup\n836 103 wild rose\n840 103 wild rose\n957 67 iris\n845 103 wild rose\n953 67 iris\n837 103 wild rose\n715 68 windflower\n958 67 iris\n722 47 buttercup\n```",
      "votes": 2
    },
    {
      "id": 797825,
      "postDate": "2020-04-04T23:46:37.820Z",
      "content": "<p>I also made tfrec version of the Oxford Flowers but filtered out mutual images. It turns out that only 2718 of 7864 images were not present in the training + validation dataset from the competition. I wrote a script that compared images within each class and removed ones with a high (&gt;0.9) Structural Similarity Index. I did a sanity check and validated a few of removed images manually - all correct. </p>\n\n<p>This version of the Oxford Flowers is available <a href=\"https://www.kaggle.com/szacho/oxford-102-for-tpu-competition\">here</a>.</p>",
      "rawMarkdown": "I also made tfrec version of the Oxford Flowers but filtered out mutual images. It turns out that only 2718 of 7864 images were not present in the training + validation dataset from the competition. I wrote a script that compared images within each class and removed ones with a high (&gt;0.9) Structural Similarity Index. I did a sanity check and validated a few of removed images manually - all correct. \n\nThis version of the Oxford Flowers is available [here](https://www.kaggle.com/szacho/oxford-102-for-tpu-competition).",
      "votes": 2,
      "replies": [
        {
          "id": 807961,
          "postDate": "2020-04-15T04:47:56.557Z",
          "content": "<p>Thanks for this. This shows the percentage of the labels made up by the various sets.</p>\n\n<p>I may be seeing patterns where there aren't any, but I thought this indicated that your filtering was pretty spot on. If you look at the classes where there don't appear to be images from other datasets, it looks like train plus val plus your filtered ox102 is the same size as the full ox102 set. </p>\n\n<p><img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-user-content/o/inbox%2F781502%2F855842737254af13534350878904344b%2F2020-04-14_21-38-24.png?generation=1586925917920104&amp;alt=media\" alt=\"\"></p>",
          "rawMarkdown": "Thanks for this. This shows the percentage of the labels made up by the various sets.\n\n I may be seeing patterns where there aren't any, but I thought this indicated that your filtering was pretty spot on. If you look at the classes where there don't appear to be images from other datasets, it looks like train plus val plus your filtered ox102 is the same size as the full ox102 set. \n\n![](https://www.googleapis.com/download/storage/v1/b/kaggle-user-content/o/inbox%2F781502%2F855842737254af13534350878904344b%2F2020-04-14_21-38-24.png?generation=1586925917920104&amp;alt=media)\n",
          "votes": 1
        }
      ]
    },
    {
      "id": 797586,
      "postDate": "2020-04-04T17:21:10.627Z",
      "content": "<p>updated:</p>\n\n<p>imagenet synset and kaggle label mapping (not 100% verified). These imagenet files can be download from the google link above.</p>\n\n<p>```\n    for <em>,</em>,name,_ in np.array([\n        22, 'fritillary', 'n02278210', 'fritillary',\n        30, 'carnation', 'n04971211', 'carnation',\n        73, 'rose', 'n04971313', 'rose, rosiness',\n        28, 'artichoke', 'n07718747', 'artichoke, globe artichoke',\n        88, 'watercress', 'n07732904', 'watercress',\n        86, 'magnolia', 'n11709674', 'magnolia',\n        77, 'lotus', 'n11717399', 'lotus, indian lotus, sacred lotus, nelumbo nucifera',\n        47, 'buttercup', 'n11720353', 'buttercup, butterflower, butter-flower, crowfoot, goldcup, kingcup',\n        8, 'monkshood', 'n11723227', 'monkshood, helmetflower, helmet flower, aconitum napellus',\n        83, 'columbine', 'n11727091', 'columbine, aquilegia, aquilege',\n        81, 'clematis', 'n11729478', 'clematis',\n        39, 'lenten rose', 'n11734493', 'lenten rose, black hellebore, helleborus orientalis',\n        80, 'frangipani', 'n11774513', 'frangipani, frangipanni',\n        79, 'anthurium', 'n11783920', 'anthurium, tailflower, tail-flower',\n        29, 'sweet william', 'n11808299', 'sweet william, dianthus barbatus',\n        30, 'carnation', 'n11808468', 'carnation, clove pink, gillyflower, dianthus caryophyllus',\n        94, 'bougainvillea', 'n11838916', 'bougainvillea',\n        78, 'toad lily', 'n11861641', 'toad lily, montia chamissoi',\n        88, 'watercress', 'n11869689', 'watercress',\n        45, 'wallflower', 'n11883328', 'wallflower, cheiranthus cheiri, erysimum cheiri',\n        45, 'wallflower', 'n11887119', 'wallflower',\n        25, 'corn poppy', 'n11902200', 'corn poppy, field poppy, flanders poppy, papaver rhoeas',\n        48, 'daisy', 'n11939491', 'daisy',\n        33, 'cosmos', 'n11958080', 'cosmos, cosmea',\n        28, 'artichoke', 'n11959632', 'artichoke, globe artichoke, artichoke plant, cynara scolymus',\n        9, 'globe thistle', 'n11962667', 'globe thistle',\n        70, 'gazania', 'n11971248', 'gazania',\n        40, 'barberton daisy', 'n11971927', 'barberton daisy, transvaal daisy, gerbera jamesonii',\n        53, 'sunflower', 'n11978233', 'sunflower, helianthus',\n        62, 'black-eyed susan', 'n12008487', 'black-eyed susan, rudbeckia hirta, rudbeckia serotina',\n        46, 'marigold', 'n12020507', 'marigold',\n        49, 'common dandelion', 'n12024445', 'common dandelion, taraxacum ruderalia, taraxacum officinale',\n        96, 'mallow', 'n12170585', 'mallow',\n        71, 'azalea', 'n12245319', 'azalea',\n        41, 'daffodil', 'n12421683', 'daffodil, narcissus pseudonarcissus',\n        5, 'tiger lily', 'n12427184', 'tiger lily, leopard lily, pine lily, lilium catesbaei',\n        5, 'tiger lily', 'n12427566', 'tiger lily, devil lily, kentan, lilium lancifolium',\n        22, 'fritillary', 'n12451915', 'fritillary, checkered lily',\n        24, 'grape hyacinth', 'n12460697', 'grape hyacinth',\n        7, 'bird of paradise', 'n12489815', 'bird of paradise, poinciana, caesalpinia gilliesii, poinciana gilliesii',\n        73, 'rose', 'n12620196', 'rose, rosebush',\n        57, 'geranium', 'n12685431', 'geranium',\n        4, 'wild geranium', 'n12686077', 'wild geranium, spotted cranesbill, geranium maculatum',\n        62, 'black-eyed susan', 'n12813189', 'black-eyed susan, black-eyed susan vine, thunbergia alata',\n        91, 'bee balm', 'n12858397', 'bee balm, beebalm, bergamot mint, oswego tea, monarda didyma',\n        91, 'bee balm', 'n12858871', 'bee balm, beebalm, monarda fistulosa',\n        10, 'snapdragon', 'n12877244', 'snapdragon',\n        93, 'foxglove', 'n12882779', 'foxglove, digitalis',\n        18, 'balloon flower', 'n12887293', 'balloon flower, scented penstemon, penstemon palmeri',\n        74, 'thorn apple', 'n12903367', 'thorn apple',\n        50, 'petunia', 'n12909421', 'petunia',\n        43, 'poinsettia', 'n12920204', 'poinsettia, christmas star, christmas flower, lobster plant, mexican flameleaf, painted leaf, euphorbia pulcherrima',\n        95, 'camellia', 'n12929403', 'camellia, camelia',\n    ]).reshape(-1,4):</p>\n\n<p>```</p>",
      "rawMarkdown": "updated:\n\nimagenet synset and kaggle label mapping (not 100% verified). These imagenet files can be download from the google link above.\n\n```\n    for _,_,name,_ in np.array([\n        22, 'fritillary', 'n02278210', 'fritillary',\n        30, 'carnation', 'n04971211', 'carnation',\n        73, 'rose', 'n04971313', 'rose, rosiness',\n        28, 'artichoke', 'n07718747', 'artichoke, globe artichoke',\n        88, 'watercress', 'n07732904', 'watercress',\n        86, 'magnolia', 'n11709674', 'magnolia',\n        77, 'lotus', 'n11717399', 'lotus, indian lotus, sacred lotus, nelumbo nucifera',\n        47, 'buttercup', 'n11720353', 'buttercup, butterflower, butter-flower, crowfoot, goldcup, kingcup',\n        8, 'monkshood', 'n11723227', 'monkshood, helmetflower, helmet flower, aconitum napellus',\n        83, 'columbine', 'n11727091', 'columbine, aquilegia, aquilege',\n        81, 'clematis', 'n11729478', 'clematis',\n        39, 'lenten rose', 'n11734493', 'lenten rose, black hellebore, helleborus orientalis',\n        80, 'frangipani', 'n11774513', 'frangipani, frangipanni',\n        79, 'anthurium', 'n11783920', 'anthurium, tailflower, tail-flower',\n        29, 'sweet william', 'n11808299', 'sweet william, dianthus barbatus',\n        30, 'carnation', 'n11808468', 'carnation, clove pink, gillyflower, dianthus caryophyllus',\n        94, 'bougainvillea', 'n11838916', 'bougainvillea',\n        78, 'toad lily', 'n11861641', 'toad lily, montia chamissoi',\n        88, 'watercress', 'n11869689', 'watercress',\n        45, 'wallflower', 'n11883328', 'wallflower, cheiranthus cheiri, erysimum cheiri',\n        45, 'wallflower', 'n11887119', 'wallflower',\n        25, 'corn poppy', 'n11902200', 'corn poppy, field poppy, flanders poppy, papaver rhoeas',\n        48, 'daisy', 'n11939491', 'daisy',\n        33, 'cosmos', 'n11958080', 'cosmos, cosmea',\n        28, 'artichoke', 'n11959632', 'artichoke, globe artichoke, artichoke plant, cynara scolymus',\n        9, 'globe thistle', 'n11962667', 'globe thistle',\n        70, 'gazania', 'n11971248', 'gazania',\n        40, 'barberton daisy', 'n11971927', 'barberton daisy, transvaal daisy, gerbera jamesonii',\n        53, 'sunflower', 'n11978233', 'sunflower, helianthus',\n        62, 'black-eyed susan', 'n12008487', 'black-eyed susan, rudbeckia hirta, rudbeckia serotina',\n        46, 'marigold', 'n12020507', 'marigold',\n        49, 'common dandelion', 'n12024445', 'common dandelion, taraxacum ruderalia, taraxacum officinale',\n        96, 'mallow', 'n12170585', 'mallow',\n        71, 'azalea', 'n12245319', 'azalea',\n        41, 'daffodil', 'n12421683', 'daffodil, narcissus pseudonarcissus',\n        5, 'tiger lily', 'n12427184', 'tiger lily, leopard lily, pine lily, lilium catesbaei',\n        5, 'tiger lily', 'n12427566', 'tiger lily, devil lily, kentan, lilium lancifolium',\n        22, 'fritillary', 'n12451915', 'fritillary, checkered lily',\n        24, 'grape hyacinth', 'n12460697', 'grape hyacinth',\n        7, 'bird of paradise', 'n12489815', 'bird of paradise, poinciana, caesalpinia gilliesii, poinciana gilliesii',\n        73, 'rose', 'n12620196', 'rose, rosebush',\n        57, 'geranium', 'n12685431', 'geranium',\n        4, 'wild geranium', 'n12686077', 'wild geranium, spotted cranesbill, geranium maculatum',\n        62, 'black-eyed susan', 'n12813189', 'black-eyed susan, black-eyed susan vine, thunbergia alata',\n        91, 'bee balm', 'n12858397', 'bee balm, beebalm, bergamot mint, oswego tea, monarda didyma',\n        91, 'bee balm', 'n12858871', 'bee balm, beebalm, monarda fistulosa',\n        10, 'snapdragon', 'n12877244', 'snapdragon',\n        93, 'foxglove', 'n12882779', 'foxglove, digitalis',\n        18, 'balloon flower', 'n12887293', 'balloon flower, scented penstemon, penstemon palmeri',\n        74, 'thorn apple', 'n12903367', 'thorn apple',\n        50, 'petunia', 'n12909421', 'petunia',\n        43, 'poinsettia', 'n12920204', 'poinsettia, christmas star, christmas flower, lobster plant, mexican flameleaf, painted leaf, euphorbia pulcherrima',\n        95, 'camellia', 'n12929403', 'camellia, camelia',\n    ]).reshape(-1,4):\n\n```",
      "votes": 2
    },
    {
      "id": 1249524,
      "postDate": "2021-03-23T11:03:33.587Z",
      "content": "<p>Thank you for sharing. <a href=\"https://www.kaggle.com/hengck23\" target=\"_blank\">@hengck23</a> Do we need to augment these different repositories on the aggregated data in view of balanced target classification?</p>",
      "rawMarkdown": "Thank you for sharing. @hengck23 Do we need to augment these different repositories on the aggregated data in view of balanced target classification?"
    },
    {
      "id": 818175,
      "postDate": "2020-04-23T17:08:29.060Z",
      "content": "<p>Thanks for these discussions, and congrats <a href=\"/bnkrg114514\">@bnkrg114514</a> for being first in the competition.</p>\n\n<p>Seems like external data is all you need 😄 😄 </p>",
      "rawMarkdown": "Thanks for these discussions, and congrats @bnkrg114514 for being first in the competition.\n\nSeems like external data is all you need 😄 😄 "
    },
    {
      "id": 808020,
      "postDate": "2020-04-15T05:21:21.230Z",
      "content": "<p>Congrats for the 1st place and thanks for sharing your updated work.</p>",
      "rawMarkdown": "Congrats for the 1st place and thanks for sharing your updated work."
    },
    {
      "id": 797523,
      "postDate": "2020-04-04T16:27:27.513Z",
      "content": "<p><a href=\"/hengck23\">@hengck23</a> Thanks for sharing</p>",
      "rawMarkdown": "@hengck23 Thanks for sharing\n",
      "votes": 1
    },
    {
      "id": 817487,
      "postDate": "2020-04-23T07:39:28.110Z",
      "content": "<p>Thank you for sharing</p>",
      "rawMarkdown": "Thank you for sharing"
    }
  ],
  "comments": [
    {
      "id": 816698,
      "author_name": "Kirill Blinov",
      "author_url": "",
      "post_date": "2020-04-22T14:20:36.470000",
      "content": "<p>Hi Heng CherKeng, thanks for sharing.  I have converted your dataset to tfrecords (just for convenience).\n<a href=\"https://www.kaggle.com/kirillblinov/tf-flower-photo-tfrec\">https://www.kaggle.com/kirillblinov/tf-flower-photo-tfrec</a></p>",
      "votes": 10,
      "replies": [
        {
          "id": 817490,
          "author_name": "あほ",
          "author_url": "",
          "post_date": "2020-04-23T07:42:33.977000",
          "content": "<p>Thank you for sharing\ni using your dataset</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 820335,
          "author_name": "Gaurav Yadav",
          "author_url": "",
          "post_date": "2020-04-25T10:51:04.360000",
          "content": "<p><a href=\"/kirillblinov\">@kirillblinov</a> How did you convert the dataset? \nI also converted Heng's dataset using the label mapping he provided in comments but the size of dataset is much different from yours.\nYou can find my dataset here(<a href=\"https://www.kaggle.com/gaur128/externaldatasettpuflowers\">https://www.kaggle.com/gaur128/externaldatasettpuflowers</a>).</p>\n\n<p>P.S Thank you for sharing, it is a lot better than mine.</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 821758,
          "author_name": "Kirill Blinov",
          "author_url": "",
          "post_date": "2020-04-26T11:56:26.593000",
          "content": "<p>Hi Gaurav Yadav, \nI have removed duplicated images using consecutively phash and dhash from <a href=\"https://pypi.org/project/ImageHash/\">ImageHash</a> library.  Structural Similarity Index works even better but requires much more time.</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 821760,
          "author_name": "Kirill Blinov",
          "author_url": "",
          "post_date": "2020-04-26T11:57:58.537000",
          "content": "<p>Hi BNK, you are welcome!</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 821829,
          "author_name": "Gaurav Yadav",
          "author_url": "",
          "post_date": "2020-04-26T12:55:38.443000",
          "content": "<p><a href=\"/kirillblinov\">@kirillblinov</a> Is it in any way possible for you to share your dataset creation code maybe after the competition over.\nAnd once again thanks for sharing your dataset, it helped a lot.</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 826143,
          "author_name": "Kirill Blinov",
          "author_url": "",
          "post_date": "2020-04-29T13:28:04.120000",
          "content": "<p>Hi Gaurav Yadav, I put some (most important part) code here:\n<a href=\"https://www.kaggle.com/kirillblinov/prepare-dataset\">https://www.kaggle.com/kirillblinov/prepare-dataset</a></p>",
          "votes": 1,
          "replies": []
        },
        {
          "id": 828988,
          "author_name": "Gaurav Yadav",
          "author_url": "",
          "post_date": "2020-05-01T12:27:54.207000",
          "content": "<p><a href=\"/kirillblinov\">@kirillblinov</a> Thanks a lot.</p>",
          "votes": 0,
          "replies": []
        }
      ]
    },
    {
      "id": 809094,
      "author_name": "Caleb",
      "author_url": "",
      "post_date": "2020-04-15T21:05:33.607000",
      "content": "<p>Here is a set of tfrecords for the openimage images included in <a href=\"/hengck23\">@hengck23</a> 's <a href=\"https://www.kaggle.com/hengck23/externaldatasettpuflower.\">dataset</a>.</p>\n\n<p><a href=\"https://www.kaggle.com/calebeverett/flowers-tpu-openimage-tfrecords\">https://www.kaggle.com/calebeverett/flowers-tpu-openimage-tfrecords</a></p>\n\n<p>I separated the roses into a separate set of records since there were so many of them. It may make sense to sample them at a lower weight.</p>",
      "votes": 3,
      "replies": []
    },
    {
      "id": 798499,
      "author_name": "hengck23",
      "author_url": "",
      "post_date": "2020-04-05T14:51:54.637000",
      "content": "<p>reference results</p>\n\n<p>```\n224x244 for kaggle data\ncenter crop and resize to 224x224 for external data</p>\n\n<p>model = se-resnex50\nsingle fold: TTA = null + flip + scale</p>\n\n<p>LB= 0.93963  (local cv on val = 0.944625) <br>\n         for  training set = train  </p>\n\n<p>LB= 0.94683 <br>\n         for  training set =  train + val</p>\n\n<p>LB= 0.95224  (local cv on val = 0.958245) <br>\n         for  training set =  train + external (oxford+tf_flower, possibly overlap with val)</p>\n\n<p>LB= 0.95788 <br>\n         for  training set = train + val + external (oxford+tf_flower, possibly overlap with val)</p>\n\n<p>LB=  0.97507 (local cv on val = 0.983) <br>\n         for  training set = train  + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)</p>\n\n<p>LB= 0.97640\n         for  training set = train  + val + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)\n```</p>",
      "votes": 4,
      "replies": [
        {
          "id": 811297,
          "author_name": "Victor Paslay",
          "author_url": "",
          "post_date": "2020-04-17T18:46:38.153000",
          "content": "<p>Thank you for sharing!\nDo you use Torch or Keras for se-resnext50?</p>",
          "votes": 0,
          "replies": []
        }
      ]
    },
    {
      "id": 836440,
      "author_name": "hengck23",
      "author_url": "",
      "post_date": "2020-05-07T01:58:50.927000",
      "content": "<h2>[update and important! on may-07]</h2>\n\n<p>please see  <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329</a>\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"</p>\n\n<p>in summary, using external labels of \"test images or their duplicates in external data\" is not allowed!</p>",
      "votes": 1,
      "replies": [
        {
          "id": 836443,
          "author_name": "hengck23",
          "author_url": "",
          "post_date": "2020-05-07T02:04:11.667000",
          "content": "<p>i haven't do a thorough and careful check. so far here are the duplicates i found. kaggler are free to contribute or double check, etc</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 836447,
          "author_name": "hengck23",
          "author_url": "",
          "post_date": "2020-05-07T02:10:39.087000",
          "content": "<p>you can easily find the duplicate images by i) cropping images to square in external data, ii) resizing the external and kaggle images to small size (e.g. 20x20 or 16x16) iii) count the number of pixel difference as image similarity measure</p>\n\n<p>the attached code is an example</p>\n\n<p>the missing function in the attch code is:</p>\n\n<p>```</p>\n\n<p>def do_center_crop(image, size=192):\n    if (size,size)!=image.shape[:2]:\n        h,w = image.shape[:2]\n        s = min(h,w)\n        x = int(((w-s)/2))\n        y = int(((h-s)/2))\n        image = image[y:y+s, x:x+s]\n        image = cv2.resize(image,dsize=(size,size),interpolation=cv2.INTER_LINEAR)\n    return image</p>\n\n<p>```</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 836460,
          "author_name": "Chris Deotte",
          "author_url": "",
          "post_date": "2020-05-07T02:24:16.410000",
          "content": "<p>That's a nice quick method. Another way to find all the duplicates is by taking the output from a CNN final hidden layer and then using RAPIDS kNN to compare external data with test data. This finds all the duplicates.</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 836628,
          "author_name": "",
          "author_url": "",
          "post_date": "2020-05-07T05:43:02.203000",
          "content": "",
          "votes": 0,
          "replies": []
        },
        {
          "id": 836693,
          "author_name": "hengck23",
          "author_url": "",
          "post_date": "2020-05-07T06:47:50.043000",
          "content": "<p>i don't think it matters.  but i do not represent kaggle. it is better you put the question in the official thread at: <a href=\"https://www.kaggle.com/c/flower-classification-with-tpus/discussion/130276\">https://www.kaggle.com/c/flower-classification-with-tpus/discussion/130276</a></p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 837725,
          "author_name": "",
          "author_url": "",
          "post_date": "2020-05-08T02:12:39.710000",
          "content": "",
          "votes": 0,
          "replies": []
        },
        {
          "id": 837889,
          "author_name": "hengck23",
          "author_url": "",
          "post_date": "2020-05-08T05:45:00.533000",
          "content": "<p>i think kaggle processes and crops the source image to kaggle square image in only one way.  it is just a simple square center crop, where size of square = min(width,height) of external source image</p>\n\n<p>you can check the original oxford images and the kaggle images. i don't think there are other sophisticated way (e.g. taking part of the source image). but i cannot be 100% sure. </p>\n\n<p>as long as there is \"no intention to cheat\" and you \"have tried your best way to filter of the test duplicates\", i think your solution would be reasonable and acceptable.</p>",
          "votes": 0,
          "replies": []
        },
        {
          "id": 837908,
          "author_name": "",
          "author_url": "",
          "post_date": "2020-05-08T06:20:58.230000",
          "content": "",
          "votes": 0,
          "replies": []
        }
      ]
    },
    {
      "id": 796816,
      "author_name": "Chris Deotte",
      "author_url": "",
      "post_date": "2020-04-04T00:22:10.927000",
      "content": "<p>Hi Heng CherKeng, I downloaded the Oxford 102 Category Flower dataset and converted it into TFRecords for everyone in the Kaggle dataset <a href=\"https://www.kaggle.com/cdeotte/oxford-flowers-tfrecords\">here</a></p>",
      "votes": 1,
      "replies": [
        {
          "id": 796912,
          "author_name": "hengck23",
          "author_url": "",
          "post_date": "2020-04-04T04:09:20.200000",
          "content": "<p><a href=\"/cdeotte\">@cdeotte</a> </p>\n\n<p>thanks for the work and link.</p>\n\n<p>we are also using oxford flowers, and also tf flowers, imagenet-21k and inaturalist, JFT-300m</p>\n\n<p>both oxford flowers and tf flowers are very clean and our experiments show  about +0.006 improvement in public LB.</p>\n\n<p>the other external  dataset has much more significant noise and we are trying to see how to use them.</p>\n\n<hr>\n\n<p>you may also want to check the paper \"Big Transfer (BiT): General Visual Representation Learning\".\n<a href=\"https://paperswithcode.com/sota/fine-grained-image-classification-on-oxford\">https://paperswithcode.com/sota/fine-grained-image-classification-on-oxford</a>\nsee laso: <a href=\"https://github.com/Gogul09/flower-recognition\">https://github.com/Gogul09/flower-recognition</a></p>\n\n<p>JFT-300M pretrained model performs better than imagenet-1K for flower classification.</p>\n\n<p>instead of using external data like imagenet-21k, inaturalist, JFT-300m directly, one may use pretrained models trained on them (if you google, you can find a few of them ). one can use the features extracted from these pretrained models, in addition to the rgb pixel, as input to your CNN.</p>",
          "votes": 2,
          "replies": []
        },
        {
          "id": 810275,
          "author_name": "Caleb",
          "author_url": "",
          "post_date": "2020-04-16T20:33:04.430000",
          "content": "<p>Here is the note on fixing the train-test resolution discrepancy referred to in the BiT paper. <a href=\"https://arxiv.org/pdf/2003.08237.pdf\">https://arxiv.org/pdf/2003.08237.pdf</a></p>",
          "votes": 1,
          "replies": []
        }
      ]
    },
    {
      "id": 799100,
      "author_name": "hengck23",
      "author_url": "",
      "post_date": "2020-04-06T07:17:54.367000",
      "content": "<p>this may seem to be good solution</p>\n\n<p>DivideMix: Learning with Noisy Labels as Semi-supervised Learning\n<a href=\"https://github.com/LiJunnan1992/DivideMix\">https://github.com/LiJunnan1992/DivideMix</a></p>\n\n<p>SELF: LEARNING TO FILTER NOISY LABELS WITH SELF-ENSEMBLING\n<a href=\"https://openreview.net/pdf?id=HkgsPhNYPS\">https://openreview.net/pdf?id=HkgsPhNYPS</a></p>\n\n<p>since external is noisy labelled, these methods may help to clean up</p>\n\n<p>others: <a href=\"https://github.com/subeeshvasu/Awesome-Learning-with-Label-Noise\">https://github.com/subeeshvasu/Awesome-Learning-with-Label-Noise</a></p>",
      "votes": 2,
      "replies": []
    },
    {
      "id": 798097,
      "author_name": "hengck23",
      "author_url": "",
      "post_date": "2020-04-05T07:09:49.827000",
      "content": "<p>inaturalist-2107/18/19 dataset.\nsee also\n<a href=\"https://github.com/visipedia/inat_comp\">https://github.com/visipedia/inat_comp</a>\n<a href=\"https://www.inaturalist.org/pages/developers\">https://www.inaturalist.org/pages/developers</a></p>\n\n<p>Note: the mapping below is not 100% correct. (e.g. 'iris and yellow iris' are separate class in kaggle, but single class some inaturalist class). you may want to refine them yourselves. The inaturalist files can be downloaded from my google drive link above. </p>\n\n<p>there are duplicate in inaturalist-2107/18/19.\nit is probably better to download the images using url provided at \"<a href=\"https://www.inaturalist.org/pages/developers\">https://www.inaturalist.org/pages/developers</a>\".\nbut i haven't try it yet.</p>\n\n<p>inaturalist-2017 mapping:\n```\n   inaturalist_2017_map=np.array([\n        'Oenothera speciosa', 'pink primrose',\n        #'Verbena halei', 'pink primrose',  # '533c84731763d1230128406839bce6a5', 'fb3dab74d'\n        'Ranunculus acris', 'buttercup',\n        'Cirsium vulgare', 'spear thistle',\n        'Cirsium discolor', 'spear thistle',\n        'Ipomoea purpurea', 'morning glory',\n        #'Ricinus communis', 'morning glory', #'95bf31471ea018c3f768b493c93ea863', '0676ef538'\n        'Viola tricolor', 'wild pansy',\n        'Lilium parvum', 'tiger lily',\n        'Anemone nemorosa', 'windflower',\n        'Anemone quinquefolia', 'windflower',\n        'Gaura suffulta', 'gaura',\n    ]).reshape(-1,2)</p>\n\n<p>```</p>\n\n<p>inaturalist-2018 mapping:\n```\n    inaturalist_2018_map=np.array([\n        '6993', 'wild geranium',\n        '6996', 'wild geranium',\n        '6997', 'wild geranium',\n        '7448', 'pink primrose',\n        '5907', 'spear thistle',\n        '7673', 'wild rose',\n        '7674', 'wild rose',\n        '7676', 'wild rose',\n        '5267', 'tiger lily',\n        '5386', 'iris',  #or yellow iris\n        '5387', 'iris',\n        '5389', 'iris',\n        '5391', 'iris',\n    ]).reshape(-1,2)</p>\n\n<p>```</p>\n\n<p>inatutalist-2019 mapping\n<code>\n653 4 wild geranium\n654 4 wild geranium\n838 103 wild rose\n629 5 tiger lily\n773 0 pink primrose\n839 103 wild rose\n831 75 morning glory\n630 51 wild pansy\n835 103 wild rose\n962 67 iris\n954 67 iris\n494 5 tiger lily\n434 0 pink primrose\n960 67 iris\n955 67 iris\n841 103 wild rose\n360 13 spear thistle\n956 14 yellow iris\n651 4 wild geranium\n501 56 gaura\n961 67 iris\n650 4 wild geranium\n646 4 wild geranium\n492 0 pink primrose\n959 67 iris\n842 103 wild rose\n834 103 wild rose\n844 103 wild rose\n843 103 wild rose\n648 4 wild geranium\n655 4 wild geranium\n721 47 buttercup\n836 103 wild rose\n840 103 wild rose\n957 67 iris\n845 103 wild rose\n953 67 iris\n837 103 wild rose\n715 68 windflower\n958 67 iris\n722 47 buttercup\n</code></p>",
      "votes": 2,
      "replies": []
    },
    {
      "id": 797825,
      "author_name": "Michał Szachniewicz",
      "author_url": "",
      "post_date": "2020-04-04T23:46:37.820000",
      "content": "<p>I also made tfrec version of the Oxford Flowers but filtered out mutual images. It turns out that only 2718 of 7864 images were not present in the training + validation dataset from the competition. I wrote a script that compared images within each class and removed ones with a high (&gt;0.9) Structural Similarity Index. I did a sanity check and validated a few of removed images manually - all correct. </p>\n\n<p>This version of the Oxford Flowers is available <a href=\"https://www.kaggle.com/szacho/oxford-102-for-tpu-competition\">here</a>.</p>",
      "votes": 2,
      "replies": [
        {
          "id": 807961,
          "author_name": "Caleb",
          "author_url": "",
          "post_date": "2020-04-15T04:47:56.557000",
          "content": "<p>Thanks for this. This shows the percentage of the labels made up by the various sets.</p>\n\n<p>I may be seeing patterns where there aren't any, but I thought this indicated that your filtering was pretty spot on. If you look at the classes where there don't appear to be images from other datasets, it looks like train plus val plus your filtered ox102 is the same size as the full ox102 set. </p>\n\n<p><img src=\"https://www.googleapis.com/download/storage/v1/b/kaggle-user-content/o/inbox%2F781502%2F855842737254af13534350878904344b%2F2020-04-14_21-38-24.png?generation=1586925917920104&amp;alt=media\" alt=\"\"></p>",
          "votes": 1,
          "replies": []
        }
      ]
    },
    {
      "id": 797586,
      "author_name": "hengck23",
      "author_url": "",
      "post_date": "2020-04-04T17:21:10.627000",
      "content": "<p>updated:</p>\n\n<p>imagenet synset and kaggle label mapping (not 100% verified). These imagenet files can be download from the google link above.</p>\n\n<p>```\n    for <em>,</em>,name,_ in np.array([\n        22, 'fritillary', 'n02278210', 'fritillary',\n        30, 'carnation', 'n04971211', 'carnation',\n        73, 'rose', 'n04971313', 'rose, rosiness',\n        28, 'artichoke', 'n07718747', 'artichoke, globe artichoke',\n        88, 'watercress', 'n07732904', 'watercress',\n        86, 'magnolia', 'n11709674', 'magnolia',\n        77, 'lotus', 'n11717399', 'lotus, indian lotus, sacred lotus, nelumbo nucifera',\n        47, 'buttercup', 'n11720353', 'buttercup, butterflower, butter-flower, crowfoot, goldcup, kingcup',\n        8, 'monkshood', 'n11723227', 'monkshood, helmetflower, helmet flower, aconitum napellus',\n        83, 'columbine', 'n11727091', 'columbine, aquilegia, aquilege',\n        81, 'clematis', 'n11729478', 'clematis',\n        39, 'lenten rose', 'n11734493', 'lenten rose, black hellebore, helleborus orientalis',\n        80, 'frangipani', 'n11774513', 'frangipani, frangipanni',\n        79, 'anthurium', 'n11783920', 'anthurium, tailflower, tail-flower',\n        29, 'sweet william', 'n11808299', 'sweet william, dianthus barbatus',\n        30, 'carnation', 'n11808468', 'carnation, clove pink, gillyflower, dianthus caryophyllus',\n        94, 'bougainvillea', 'n11838916', 'bougainvillea',\n        78, 'toad lily', 'n11861641', 'toad lily, montia chamissoi',\n        88, 'watercress', 'n11869689', 'watercress',\n        45, 'wallflower', 'n11883328', 'wallflower, cheiranthus cheiri, erysimum cheiri',\n        45, 'wallflower', 'n11887119', 'wallflower',\n        25, 'corn poppy', 'n11902200', 'corn poppy, field poppy, flanders poppy, papaver rhoeas',\n        48, 'daisy', 'n11939491', 'daisy',\n        33, 'cosmos', 'n11958080', 'cosmos, cosmea',\n        28, 'artichoke', 'n11959632', 'artichoke, globe artichoke, artichoke plant, cynara scolymus',\n        9, 'globe thistle', 'n11962667', 'globe thistle',\n        70, 'gazania', 'n11971248', 'gazania',\n        40, 'barberton daisy', 'n11971927', 'barberton daisy, transvaal daisy, gerbera jamesonii',\n        53, 'sunflower', 'n11978233', 'sunflower, helianthus',\n        62, 'black-eyed susan', 'n12008487', 'black-eyed susan, rudbeckia hirta, rudbeckia serotina',\n        46, 'marigold', 'n12020507', 'marigold',\n        49, 'common dandelion', 'n12024445', 'common dandelion, taraxacum ruderalia, taraxacum officinale',\n        96, 'mallow', 'n12170585', 'mallow',\n        71, 'azalea', 'n12245319', 'azalea',\n        41, 'daffodil', 'n12421683', 'daffodil, narcissus pseudonarcissus',\n        5, 'tiger lily', 'n12427184', 'tiger lily, leopard lily, pine lily, lilium catesbaei',\n        5, 'tiger lily', 'n12427566', 'tiger lily, devil lily, kentan, lilium lancifolium',\n        22, 'fritillary', 'n12451915', 'fritillary, checkered lily',\n        24, 'grape hyacinth', 'n12460697', 'grape hyacinth',\n        7, 'bird of paradise', 'n12489815', 'bird of paradise, poinciana, caesalpinia gilliesii, poinciana gilliesii',\n        73, 'rose', 'n12620196', 'rose, rosebush',\n        57, 'geranium', 'n12685431', 'geranium',\n        4, 'wild geranium', 'n12686077', 'wild geranium, spotted cranesbill, geranium maculatum',\n        62, 'black-eyed susan', 'n12813189', 'black-eyed susan, black-eyed susan vine, thunbergia alata',\n        91, 'bee balm', 'n12858397', 'bee balm, beebalm, bergamot mint, oswego tea, monarda didyma',\n        91, 'bee balm', 'n12858871', 'bee balm, beebalm, monarda fistulosa',\n        10, 'snapdragon', 'n12877244', 'snapdragon',\n        93, 'foxglove', 'n12882779', 'foxglove, digitalis',\n        18, 'balloon flower', 'n12887293', 'balloon flower, scented penstemon, penstemon palmeri',\n        74, 'thorn apple', 'n12903367', 'thorn apple',\n        50, 'petunia', 'n12909421', 'petunia',\n        43, 'poinsettia', 'n12920204', 'poinsettia, christmas star, christmas flower, lobster plant, mexican flameleaf, painted leaf, euphorbia pulcherrima',\n        95, 'camellia', 'n12929403', 'camellia, camelia',\n    ]).reshape(-1,4):</p>\n\n<p>```</p>",
      "votes": 2,
      "replies": []
    },
    {
      "id": 1249524,
      "author_name": "Olusesi Adebisi",
      "author_url": "",
      "post_date": "2021-03-23T11:03:33.587000",
      "content": "<p>Thank you for sharing. <a href=\"https://www.kaggle.com/hengck23\" target=\"_blank\">@hengck23</a> Do we need to augment these different repositories on the aggregated data in view of balanced target classification?</p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 818175,
      "author_name": "Kurian Benoy",
      "author_url": "",
      "post_date": "2020-04-23T17:08:29.060000",
      "content": "<p>Thanks for these discussions, and congrats <a href=\"/bnkrg114514\">@bnkrg114514</a> for being first in the competition.</p>\n\n<p>Seems like external data is all you need 😄 😄 </p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 808020,
      "author_name": "Mohammed Deeb",
      "author_url": "",
      "post_date": "2020-04-15T05:21:21.230000",
      "content": "<p>Congrats for the 1st place and thanks for sharing your updated work.</p>",
      "votes": 0,
      "replies": []
    },
    {
      "id": 797523,
      "author_name": "Saurav Anand",
      "author_url": "",
      "post_date": "2020-04-04T16:27:27.513000",
      "content": "<p><a href=\"/hengck23\">@hengck23</a> Thanks for sharing</p>",
      "votes": 1,
      "replies": []
    },
    {
      "id": 817487,
      "author_name": "あほ",
      "author_url": "",
      "post_date": "2020-04-23T07:39:28.110000",
      "content": "<p>Thank you for sharing</p>",
      "votes": 0,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "796326": "##[update and important! on may-07]##\nplease see  https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"\n\nin summary, using external labels of \"test images or their duplicates in external data\" is not allowed!\n\n----\nthis thread will be constantly update as i download more data.\nother kaggler are welcome to contribute. see also this thread for use of external data: https://www.kaggle.com/c/flower-classification-with-tpus/discussion/134701\n\ngoogle drive: \nhttps://drive.google.com/open?id=1yOZjOY3z7Dtki9KRpNxQK6FTO7Uq3IhL\n\nkaggle dataset\nhttps://www.kaggle.com/hengck23/externaldatasettpuflower\n \n\n---\n\nfor imagenet:\n- please refer to \"download\\_code\" to see how you can download your own file\n- see also : https://medium.com/coinmonks/how-to-get-images-from-imagenet-with-python-in-google-colaboratory-aeef5c1c45e5\n\n---\n\nwe are still working on this this but here is how we setup the problem for this challenge:\n\n1)dataset: \n- kaggle train (labelled) and test (unlabelled)\n- external data (labelled but using different labeling)\n   - Conversion to kaggle label is sometime unknown. Some external label may not even present in kaggle label \n   - some label in external data are incorrect. Some images are just noisy image (e.g. just contains leaves and no flower,)\n\n2)learning and loss\n- cross entropy for kaggle train data\n- some novel loss for external data to take care of unknown mapping and label noise\n",
    "816698": "Hi Heng CherKeng, thanks for sharing.  I have converted your dataset to tfrecords (just for convenience).\nhttps://www.kaggle.com/kirillblinov/tf-flower-photo-tfrec\n",
    "809094": "Here is a set of tfrecords for the openimage images included in @hengck23 's [dataset](https://www.kaggle.com/hengck23/externaldatasettpuflower.).\n\nhttps://www.kaggle.com/calebeverett/flowers-tpu-openimage-tfrecords\n\nI separated the roses into a separate set of records since there were so many of them. It may make sense to sample them at a lower weight.",
    "798499": "reference results\n\n```\n224x244 for kaggle data\ncenter crop and resize to 224x224 for external data\n\nmodel = se-resnex50\nsingle fold: TTA = null + flip + scale\n\n\n LB= 0.93963  (local cv on val = 0.944625)   \n         for  training set = train  \n\n LB= 0.94683                                                                             \n         for  training set =  train + val\n\n LB= 0.95224  (local cv on val = 0.958245)                             \n         for  training set =  train + external (oxford+tf_flower, possibly overlap with val)\n\n LB= 0.95788                                                                              \n         for  training set = train + val + external (oxford+tf_flower, possibly overlap with val)\n\nLB=  0.97507 (local cv on val = 0.983)   \n         for  training set = train  + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)\n\n\nLB= 0.97640\n         for  training set = train  + val + external (oxford+tf_flower+imagenet+inaturalist+openimage, possibly overlap with val)\n```",
    "836440": "##[update and important! on may-07]##\n\nplease see  https://www.kaggle.com/c/flower-classification-with-tpus/discussion/148329\n\" using some pre-labeled version of that data.\" ...  \"So yes, for complete avoidance of doubt, don't use images that are or are the same as the test set's images.\"\n\nin summary, using external labels of \"test images or their duplicates in external data\" is not allowed!\n",
    "796816": "Hi Heng CherKeng, I downloaded the Oxford 102 Category Flower dataset and converted it into TFRecords for everyone in the Kaggle dataset [here][1]\n\n[1]: https://www.kaggle.com/cdeotte/oxford-flowers-tfrecords",
    "799100": "this may seem to be good solution\n\nDivideMix: Learning with Noisy Labels as Semi-supervised Learning\nhttps://github.com/LiJunnan1992/DivideMix\n\nSELF: LEARNING TO FILTER NOISY LABELS WITH SELF-ENSEMBLING\nhttps://openreview.net/pdf?id=HkgsPhNYPS\n\n\nsince external is noisy labelled, these methods may help to clean up\n\nothers: https://github.com/subeeshvasu/Awesome-Learning-with-Label-Noise",
    "798097": "inaturalist-2107/18/19 dataset.\nsee also\nhttps://github.com/visipedia/inat_comp\nhttps://www.inaturalist.org/pages/developers\n\n\nNote: the mapping below is not 100% correct. (e.g. 'iris and yellow iris' are separate class in kaggle, but single class some inaturalist class). you may want to refine them yourselves. The inaturalist files can be downloaded from my google drive link above. \n\n\nthere are duplicate in inaturalist-2107/18/19.\nit is probably better to download the images using url provided at \"https://www.inaturalist.org/pages/developers\".\nbut i haven't try it yet.\n\n\ninaturalist-2017 mapping:\n```\n   inaturalist_2017_map=np.array([\n        'Oenothera speciosa', 'pink primrose',\n        #'Verbena halei', 'pink primrose',  # '533c84731763d1230128406839bce6a5', 'fb3dab74d'\n        'Ranunculus acris', 'buttercup',\n        'Cirsium vulgare', 'spear thistle',\n        'Cirsium discolor', 'spear thistle',\n        'Ipomoea purpurea', 'morning glory',\n        #'Ricinus communis', 'morning glory', #'95bf31471ea018c3f768b493c93ea863', '0676ef538'\n        'Viola tricolor', 'wild pansy',\n        'Lilium parvum', 'tiger lily',\n        'Anemone nemorosa', 'windflower',\n        'Anemone quinquefolia', 'windflower',\n        'Gaura suffulta', 'gaura',\n    ]).reshape(-1,2)\n\n```\n\ninaturalist-2018 mapping:\n```\n    inaturalist_2018_map=np.array([\n        '6993', 'wild geranium',\n        '6996', 'wild geranium',\n        '6997', 'wild geranium',\n        '7448', 'pink primrose',\n        '5907', 'spear thistle',\n        '7673', 'wild rose',\n        '7674', 'wild rose',\n        '7676', 'wild rose',\n        '5267', 'tiger lily',\n        '5386', 'iris',  #or yellow iris\n        '5387', 'iris',\n        '5389', 'iris',\n        '5391', 'iris',\n    ]).reshape(-1,2)\n\n```\n\n\ninatutalist-2019 mapping\n```\n653 4 wild geranium\n654 4 wild geranium\n838 103 wild rose\n629 5 tiger lily\n773 0 pink primrose\n839 103 wild rose\n831 75 morning glory\n630 51 wild pansy\n835 103 wild rose\n962 67 iris\n954 67 iris\n494 5 tiger lily\n434 0 pink primrose\n960 67 iris\n955 67 iris\n841 103 wild rose\n360 13 spear thistle\n956 14 yellow iris\n651 4 wild geranium\n501 56 gaura\n961 67 iris\n650 4 wild geranium\n646 4 wild geranium\n492 0 pink primrose\n959 67 iris\n842 103 wild rose\n834 103 wild rose\n844 103 wild rose\n843 103 wild rose\n648 4 wild geranium\n655 4 wild geranium\n721 47 buttercup\n836 103 wild rose\n840 103 wild rose\n957 67 iris\n845 103 wild rose\n953 67 iris\n837 103 wild rose\n715 68 windflower\n958 67 iris\n722 47 buttercup\n```",
    "797825": "I also made tfrec version of the Oxford Flowers but filtered out mutual images. It turns out that only 2718 of 7864 images were not present in the training + validation dataset from the competition. I wrote a script that compared images within each class and removed ones with a high (&gt;0.9) Structural Similarity Index. I did a sanity check and validated a few of removed images manually - all correct. \n\nThis version of the Oxford Flowers is available [here](https://www.kaggle.com/szacho/oxford-102-for-tpu-competition).",
    "797586": "updated:\n\nimagenet synset and kaggle label mapping (not 100% verified). These imagenet files can be download from the google link above.\n\n```\n    for _,_,name,_ in np.array([\n        22, 'fritillary', 'n02278210', 'fritillary',\n        30, 'carnation', 'n04971211', 'carnation',\n        73, 'rose', 'n04971313', 'rose, rosiness',\n        28, 'artichoke', 'n07718747', 'artichoke, globe artichoke',\n        88, 'watercress', 'n07732904', 'watercress',\n        86, 'magnolia', 'n11709674', 'magnolia',\n        77, 'lotus', 'n11717399', 'lotus, indian lotus, sacred lotus, nelumbo nucifera',\n        47, 'buttercup', 'n11720353', 'buttercup, butterflower, butter-flower, crowfoot, goldcup, kingcup',\n        8, 'monkshood', 'n11723227', 'monkshood, helmetflower, helmet flower, aconitum napellus',\n        83, 'columbine', 'n11727091', 'columbine, aquilegia, aquilege',\n        81, 'clematis', 'n11729478', 'clematis',\n        39, 'lenten rose', 'n11734493', 'lenten rose, black hellebore, helleborus orientalis',\n        80, 'frangipani', 'n11774513', 'frangipani, frangipanni',\n        79, 'anthurium', 'n11783920', 'anthurium, tailflower, tail-flower',\n        29, 'sweet william', 'n11808299', 'sweet william, dianthus barbatus',\n        30, 'carnation', 'n11808468', 'carnation, clove pink, gillyflower, dianthus caryophyllus',\n        94, 'bougainvillea', 'n11838916', 'bougainvillea',\n        78, 'toad lily', 'n11861641', 'toad lily, montia chamissoi',\n        88, 'watercress', 'n11869689', 'watercress',\n        45, 'wallflower', 'n11883328', 'wallflower, cheiranthus cheiri, erysimum cheiri',\n        45, 'wallflower', 'n11887119', 'wallflower',\n        25, 'corn poppy', 'n11902200', 'corn poppy, field poppy, flanders poppy, papaver rhoeas',\n        48, 'daisy', 'n11939491', 'daisy',\n        33, 'cosmos', 'n11958080', 'cosmos, cosmea',\n        28, 'artichoke', 'n11959632', 'artichoke, globe artichoke, artichoke plant, cynara scolymus',\n        9, 'globe thistle', 'n11962667', 'globe thistle',\n        70, 'gazania', 'n11971248', 'gazania',\n        40, 'barberton daisy', 'n11971927', 'barberton daisy, transvaal daisy, gerbera jamesonii',\n        53, 'sunflower', 'n11978233', 'sunflower, helianthus',\n        62, 'black-eyed susan', 'n12008487', 'black-eyed susan, rudbeckia hirta, rudbeckia serotina',\n        46, 'marigold', 'n12020507', 'marigold',\n        49, 'common dandelion', 'n12024445', 'common dandelion, taraxacum ruderalia, taraxacum officinale',\n        96, 'mallow', 'n12170585', 'mallow',\n        71, 'azalea', 'n12245319', 'azalea',\n        41, 'daffodil', 'n12421683', 'daffodil, narcissus pseudonarcissus',\n        5, 'tiger lily', 'n12427184', 'tiger lily, leopard lily, pine lily, lilium catesbaei',\n        5, 'tiger lily', 'n12427566', 'tiger lily, devil lily, kentan, lilium lancifolium',\n        22, 'fritillary', 'n12451915', 'fritillary, checkered lily',\n        24, 'grape hyacinth', 'n12460697', 'grape hyacinth',\n        7, 'bird of paradise', 'n12489815', 'bird of paradise, poinciana, caesalpinia gilliesii, poinciana gilliesii',\n        73, 'rose', 'n12620196', 'rose, rosebush',\n        57, 'geranium', 'n12685431', 'geranium',\n        4, 'wild geranium', 'n12686077', 'wild geranium, spotted cranesbill, geranium maculatum',\n        62, 'black-eyed susan', 'n12813189', 'black-eyed susan, black-eyed susan vine, thunbergia alata',\n        91, 'bee balm', 'n12858397', 'bee balm, beebalm, bergamot mint, oswego tea, monarda didyma',\n        91, 'bee balm', 'n12858871', 'bee balm, beebalm, monarda fistulosa',\n        10, 'snapdragon', 'n12877244', 'snapdragon',\n        93, 'foxglove', 'n12882779', 'foxglove, digitalis',\n        18, 'balloon flower', 'n12887293', 'balloon flower, scented penstemon, penstemon palmeri',\n        74, 'thorn apple', 'n12903367', 'thorn apple',\n        50, 'petunia', 'n12909421', 'petunia',\n        43, 'poinsettia', 'n12920204', 'poinsettia, christmas star, christmas flower, lobster plant, mexican flameleaf, painted leaf, euphorbia pulcherrima',\n        95, 'camellia', 'n12929403', 'camellia, camelia',\n    ]).reshape(-1,4):\n\n```",
    "1249524": "Thank you for sharing. @hengck23 Do we need to augment these different repositories on the aggregated data in view of balanced target classification?",
    "818175": "Thanks for these discussions, and congrats @bnkrg114514 for being first in the competition.\n\nSeems like external data is all you need 😄 😄 ",
    "808020": "Congrats for the 1st place and thanks for sharing your updated work.",
    "797523": "@hengck23 Thanks for sharing\n",
    "817487": "Thank you for sharing"
  }
}