{
  "id": 397213,
  "title": "Window selection for BirdCLEF",
  "url": "/competitions/birdclef-2023/discussion/397213",
  "author_name": "",
  "post_date": "2023-03-24T15:43:54.223295300Z",
  "votes": 4,
  "comment_count": 7,
  "views": 0,
  "content": "<p>Hey everyone,</p>\n<p>it is my first try on the BirdCLEF challenge and one thing I find particularly interesting is how to choose window size and how to sample/select from the available windows.</p>\n<p>From <a href=\"https://www.kaggle.com/competitions/birdclef-2021/discussion/230733\" target=\"_blank\">this</a> discussion I took away that a good heuristics is to just take the first 5 seconds in each recording.</p>\n<p>I made a notebook to explore each available (non-overlapping) 5-second window: <a href=\"https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data\" target=\"_blank\">https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data</a></p>\n<p>It seems to me that a more elaborate selection process might be beneficial, especially for classes with few samples.</p>\n<p>Are there any experiences you can share (from previous BirdCLEFs maybe) regarding a good window size, overlaps and sampling strategy?</p>\n<p>Best,</p>\n<p>Stefan</p>",
  "messages": [
    {
      "id": "2195376",
      "postDate": "03/24/2023 15:43:54",
      "content": "<p>Hey everyone,</p>\n<p>it is my first try on the BirdCLEF challenge and one thing I find particularly interesting is how to choose window size and how to sample/select from the available windows.</p>\n<p>From <a href=\"https://www.kaggle.com/competitions/birdclef-2021/discussion/230733\" target=\"_blank\">this</a> discussion I took away that a good heuristics is to just take the first 5 seconds in each recording.</p>\n<p>I made a notebook to explore each available (non-overlapping) 5-second window: <a href=\"https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data\" target=\"_blank\">https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data</a></p>\n<p>It seems to me that a more elaborate selection process might be beneficial, especially for classes with few samples.</p>\n<p>Are there any experiences you can share (from previous BirdCLEFs maybe) regarding a good window size, overlaps and sampling strategy?</p>\n<p>Best,</p>\n<p>Stefan</p>",
      "rawMarkdown": "Hey everyone,\n\nit is my first try on the BirdCLEF challenge and one thing I find particularly interesting is how to choose window size and how to sample/select from the available windows.\n\nFrom [this](https://www.kaggle.com/competitions/birdclef-2021/discussion/230733) discussion I took away that a good heuristics is to just take the first 5 seconds in each recording.\n\nI made a notebook to explore each available (non-overlapping) 5-second window: https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data\n\nIt seems to me that a more elaborate selection process might be beneficial, especially for classes with few samples.\n\nAre there any experiences you can share (from previous BirdCLEFs maybe) regarding a good window size, overlaps and sampling strategy?\n\nBest,\n\nStefan",
      "votes": null
    },
    {
      "id": "2196349",
      "postDate": "03/25/2023 10:39:56",
      "content": "<p>Hello Stefan, <br>\nI'm totally agree with you, yesterday I found the oneset_detection, that I can use to detect and select the most interisting 5s, but i remember that is another method to dectect sound window in a file, if I found something else Iwill share with you.</p>",
      "rawMarkdown": "Hello Stefan, \nI'm totally agree with you, yesterday I found the oneset_detection, that I can use to detect and select the most interisting 5s, but i remember that is another method to dectect sound window in a file, if I found something else Iwill share with you.",
      "votes": null
    },
    {
      "id": "2196752",
      "postDate": "03/25/2023 16:33:44",
      "content": "<p>Hi Aymen,</p>\n<p>thanks for the answer, this sounds interesting. Are you using the librosa function?<br>\n<a href=\"https://librosa.org/doc/main/generated/librosa.onset.onset_detect.html\" target=\"_blank\">https://librosa.org/doc/main/generated/librosa.onset.onset_detect.html</a></p>\n<p>Or can you recommend a different library / heuristics?</p>\n<p>Best,</p>\n<p>Stefan</p>",
      "rawMarkdown": "Hi Aymen,\n\nthanks for the answer, this sounds interesting. Are you using the librosa function?\nhttps://librosa.org/doc/main/generated/librosa.onset.onset_detect.html\n\nOr can you recommend a different library / heuristics?\n\nBest,\n\nStefan",
      "votes": null
    },
    {
      "id": "2197584",
      "postDate": "03/26/2023 08:30:33",
      "content": "<p>Yes, this one, I'm trying to combine this method from librosa to find out a solution to detect useful window in an audio file, I will share a notebook about my work in next few days. chatGPT give this solution (combine onset_detectiom with librosa.effects.trim) I will try it out : <a href=\"https://sharegpt.com/c/kKzbg36\" target=\"_blank\">https://sharegpt.com/c/kKzbg36</a></p>",
      "rawMarkdown": "Yes, this one, I'm trying to combine this method from librosa to find out a solution to detect useful window in an audio file, I will share a notebook about my work in next few days. chatGPT give this solution (combine onset_detectiom with librosa.effects.trim) I will try it out : https://sharegpt.com/c/kKzbg36",
      "votes": null
    },
    {
      "id": "2197927",
      "postDate": "03/26/2023 14:58:42",
      "content": "<p>:-) Looking forward to seeing the solution in your notebook. Ping me, when it's ready!</p>",
      "rawMarkdown": ":-) Looking forward to seeing the solution in your notebook. Ping me, when it's ready!",
      "votes": null
    },
    {
      "id": "2200206",
      "postDate": "03/28/2023 11:20:41",
      "content": "<p>here is my notebook<br>\n<a href=\"https://www.kaggle.com/code/aymentabib/onset-detection/notebook?scriptVersionId=123666149\" target=\"_blank\">https://www.kaggle.com/code/aymentabib/onset-detection/notebook?scriptVersionId=123666149</a></p>",
      "rawMarkdown": "here is my notebook\nhttps://www.kaggle.com/code/aymentabib/onset-detection/notebook?scriptVersionId=123666149",
      "votes": null
    },
    {
      "id": "2200218",
      "postDate": "03/28/2023 11:31:32",
      "content": "<p>in the next step I will use the number of onset_detection to decide which 5s frame to select, I will explore the onsset_detection distribution to take thsi decision.. </p>",
      "rawMarkdown": "in the next step I will use the number of onset_detection to decide which 5s frame to select, I will explore the onsset_detection distribution to take thsi decision..",
      "votes": null
    },
    {
      "id": "2200440",
      "postDate": "03/28/2023 14:58:52",
      "content": "<p>This is interesting! I ran your code in my notebook ( <a href=\"https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data\" target=\"_blank\">https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data</a>) and visualized the results: It seems to me that the onset detection from librosa is not working that well. Have you inspected some files to verify the results? </p>\n<p>It might make sense to run the onset detection on the whole recording, but not on the 5 second windows.</p>",
      "rawMarkdown": "This is interesting! I ran your code in my notebook ( https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data) and visualized the results: It seems to me that the onset detection from librosa is not working that well. Have you inspected some files to verify the results? \n\nIt might make sense to run the onset detection on the whole recording, but not on the 5 second windows.",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 2196349,
      "author_name": "aymentabib",
      "author_url": "",
      "post_date": "03/25/2023 10:39:56",
      "content": "<p>Hello Stefan, <br>\nI'm totally agree with you, yesterday I found the oneset_detection, that I can use to detect and select the most interisting 5s, but i remember that is another method to dectect sound window in a file, if I found something else Iwill share with you.</p>",
      "votes": null,
      "replies": [
        {
          "id": 2196752,
          "author_name": "sps444",
          "author_url": "",
          "post_date": "03/25/2023 16:33:44",
          "content": "<p>Hi Aymen,</p>\n<p>thanks for the answer, this sounds interesting. Are you using the librosa function?<br>\n<a href=\"https://librosa.org/doc/main/generated/librosa.onset.onset_detect.html\" target=\"_blank\">https://librosa.org/doc/main/generated/librosa.onset.onset_detect.html</a></p>\n<p>Or can you recommend a different library / heuristics?</p>\n<p>Best,</p>\n<p>Stefan</p>",
          "votes": null,
          "replies": [
            {
              "id": 2197584,
              "author_name": "aymentabib",
              "author_url": "",
              "post_date": "03/26/2023 08:30:33",
              "content": "<p>Yes, this one, I'm trying to combine this method from librosa to find out a solution to detect useful window in an audio file, I will share a notebook about my work in next few days. chatGPT give this solution (combine onset_detectiom with librosa.effects.trim) I will try it out : <a href=\"https://sharegpt.com/c/kKzbg36\" target=\"_blank\">https://sharegpt.com/c/kKzbg36</a></p>",
              "votes": null,
              "replies": [
                {
                  "id": 2197927,
                  "author_name": "sps444",
                  "author_url": "",
                  "post_date": "03/26/2023 14:58:42",
                  "content": "<p>:-) Looking forward to seeing the solution in your notebook. Ping me, when it's ready!</p>",
                  "votes": null,
                  "replies": [
                    {
                      "id": 2200206,
                      "author_name": "aymentabib",
                      "author_url": "",
                      "post_date": "03/28/2023 11:20:41",
                      "content": "<p>here is my notebook<br>\n<a href=\"https://www.kaggle.com/code/aymentabib/onset-detection/notebook?scriptVersionId=123666149\" target=\"_blank\">https://www.kaggle.com/code/aymentabib/onset-detection/notebook?scriptVersionId=123666149</a></p>",
                      "votes": null,
                      "replies": [
                        {
                          "id": 2200218,
                          "author_name": "aymentabib",
                          "author_url": "",
                          "post_date": "03/28/2023 11:31:32",
                          "content": "<p>in the next step I will use the number of onset_detection to decide which 5s frame to select, I will explore the onsset_detection distribution to take thsi decision.. </p>",
                          "votes": null,
                          "replies": [
                            {
                              "id": 2200440,
                              "author_name": "sps444",
                              "author_url": "",
                              "post_date": "03/28/2023 14:58:52",
                              "content": "<p>This is interesting! I ran your code in my notebook ( <a href=\"https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data\" target=\"_blank\">https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data</a>) and visualized the results: It seems to me that the onset detection from librosa is not working that well. Have you inspected some files to verify the results? </p>\n<p>It might make sense to run the onset detection on the whole recording, but not on the 5 second windows.</p>",
                              "votes": null,
                              "replies": []
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    }
  ],
  "raw_markdown_by_id": {
    "2195376": "Hey everyone,\n\nit is my first try on the BirdCLEF challenge and one thing I find particularly interesting is how to choose window size and how to sample/select from the available windows.\n\nFrom [this](https://www.kaggle.com/competitions/birdclef-2021/discussion/230733) discussion I took away that a good heuristics is to just take the first 5 seconds in each recording.\n\nI made a notebook to explore each available (non-overlapping) 5-second window: https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data\n\nIt seems to me that a more elaborate selection process might be beneficial, especially for classes with few samples.\n\nAre there any experiences you can share (from previous BirdCLEFs maybe) regarding a good window size, overlaps and sampling strategy?\n\nBest,\n\nStefan",
    "2196349": "Hello Stefan, \nI'm totally agree with you, yesterday I found the oneset_detection, that I can use to detect and select the most interisting 5s, but i remember that is another method to dectect sound window in a file, if I found something else Iwill share with you.",
    "2196752": "Hi Aymen,\n\nthanks for the answer, this sounds interesting. Are you using the librosa function?\nhttps://librosa.org/doc/main/generated/librosa.onset.onset_detect.html\n\nOr can you recommend a different library / heuristics?\n\nBest,\n\nStefan",
    "2197584": "Yes, this one, I'm trying to combine this method from librosa to find out a solution to detect useful window in an audio file, I will share a notebook about my work in next few days. chatGPT give this solution (combine onset_detectiom with librosa.effects.trim) I will try it out : https://sharegpt.com/c/kKzbg36",
    "2197927": ":-) Looking forward to seeing the solution in your notebook. Ping me, when it's ready!",
    "2200206": "here is my notebook\nhttps://www.kaggle.com/code/aymentabib/onset-detection/notebook?scriptVersionId=123666149",
    "2200218": "in the next step I will use the number of onset_detection to decide which 5s frame to select, I will explore the onsset_detection distribution to take thsi decision..",
    "2200440": "This is interesting! I ran your code in my notebook ( https://www.kaggle.com/code/sps444/birdclef-2023-interactive-eda-windowed-data) and visualized the results: It seems to me that the onset detection from librosa is not working that well. Have you inspected some files to verify the results? \n\nIt might make sense to run the onset detection on the whole recording, but not on the 5 second windows."
  },
  "source": "meta"
}