{
  "id": 1937,
  "title": "Bug in databatch.m",
  "url": "/competitions/GestureChallenge2/discussion/1937",
  "author_name": "",
  "post_date": "2012-05-21T18:43:49.233Z",
  "votes": null,
  "comment_count": 2,
  "views": 2241,
  "content": "<p>Hi,</p>\r\n<p>I am learning to work with the sample code you have provided, and I believe I found a bug.&nbsp;It is in the databatch.m file, in function goto(this, num) (line 131)</p>\r\n<p>Problem is in the condition -&nbsp;<span style=\"font-family:'courier new',courier\">if num~=this.current_index &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>If causes problems when databatch.invidx isn't the same as databatch.subidx. For example, when you send for testing only the test set, like you do in main.m. In this case, it doesn't evaluate the first video of the test set, but evaluates first video in\r\n train set instead, because current_index isn't changed from it's initial value in first loop.</p>\r\n<p>I think the right contition is&nbsp;<span style=\"font-family:'courier new',courier\">if\r\n<strong>this.current_index~=this.subidx(num)</strong> &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>Your score using Principal Motion algorithm is 0.39912. I scored 0.37866 only thanks to change in this condition.</p>",
  "messages": [
    {
      "id": "11148",
      "postDate": "05/21/2012 18:43:49",
      "content": "<p>Hi,</p>\r\n<p>I am learning to work with the sample code you have provided, and I believe I found a bug.&nbsp;It is in the databatch.m file, in function goto(this, num) (line 131)</p>\r\n<p>Problem is in the condition -&nbsp;<span style=\"font-family:'courier new',courier\">if num~=this.current_index &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>If causes problems when databatch.invidx isn't the same as databatch.subidx. For example, when you send for testing only the test set, like you do in main.m. In this case, it doesn't evaluate the first video of the test set, but evaluates first video in\r\n train set instead, because current_index isn't changed from it's initial value in first loop.</p>\r\n<p>I think the right contition is&nbsp;<span style=\"font-family:'courier new',courier\">if\r\n<strong>this.current_index~=this.subidx(num)</strong> &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>Your score using Principal Motion algorithm is 0.39912. I scored 0.37866 only thanks to change in this condition.</p>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "11158",
      "postDate": "05/22/2012 22:10:47",
      "content": "<p>Hi,</p>\r\n<p>This bug was there in Round 1 too. I repoted the bug in round 1, but i think its not yet fixed ;)</p>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "11225",
      "postDate": "05/25/2012 23:41:27",
      "content": "<p>[quote=Kubo Konecny;11148]</p>\r\n<p>Hi,</p>\r\n<p>I am learning to work with the sample code you have provided, and I believe I found a bug.&nbsp;It is in the databatch.m file, in function goto(this, num) (line 131)</p>\r\n<p>Problem is in the condition -&nbsp;<span style=\"font-family:'courier new',courier\">if num~=this.current_index &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>If causes problems when databatch.invidx isn't the same as databatch.subidx. For example, when you send for testing only the test set, like you do in main.m. In this case, it doesn't evaluate the first video of the test set, but evaluates first video in\r\n train set instead, because current_index isn't changed from it's initial value in first loop.</p>\r\n<p>I think the right contition is&nbsp;<span style=\"font-family:'courier new',courier\">if\r\n<strong>this.current_index~=this.subidx(num)</strong> &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>Your score using Principal Motion algorithm is 0.39912. I scored 0.37866 only thanks to change in this condition.</p>\r\n<p>[/quote]</p>\r\n<p>&nbsp;</p>\r\n<p>Thank you for pointing out this problem. I corrected the bug and posted a new version.</p>\r\n<p>For those of you who just want to correct this in code already downloaded, the but is in the goto function of databatch,m in the @databatch directory. Just remove the first condition &quot;num~=this.current_index &amp;&amp;&quot;.</p>\r\n<p>Isabelle</p>",
      "rawMarkdown": "",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 11158,
      "author_name": "mrkaggler",
      "author_url": "",
      "post_date": "05/22/2012 22:10:47",
      "content": "<p>Hi,</p>\r\n<p>This bug was there in Round 1 too. I repoted the bug in round 1, but i think its not yet fixed ;)</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 11225,
      "author_name": "iguyon",
      "author_url": "",
      "post_date": "05/25/2012 23:41:27",
      "content": "<p>[quote=Kubo Konecny;11148]</p>\r\n<p>Hi,</p>\r\n<p>I am learning to work with the sample code you have provided, and I believe I found a bug.&nbsp;It is in the databatch.m file, in function goto(this, num) (line 131)</p>\r\n<p>Problem is in the condition -&nbsp;<span style=\"font-family:'courier new',courier\">if num~=this.current_index &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>If causes problems when databatch.invidx isn't the same as databatch.subidx. For example, when you send for testing only the test set, like you do in main.m. In this case, it doesn't evaluate the first video of the test set, but evaluates first video in\r\n train set instead, because current_index isn't changed from it's initial value in first loop.</p>\r\n<p>I think the right contition is&nbsp;<span style=\"font-family:'courier new',courier\">if\r\n<strong>this.current_index~=this.subidx(num)</strong> &amp;&amp; num&gt;0 &amp;&amp; num</span></p>\r\n<p>Your score using Principal Motion algorithm is 0.39912. I scored 0.37866 only thanks to change in this condition.</p>\r\n<p>[/quote]</p>\r\n<p>&nbsp;</p>\r\n<p>Thank you for pointing out this problem. I corrected the bug and posted a new version.</p>\r\n<p>For those of you who just want to correct this in code already downloaded, the but is in the goto function of databatch,m in the @databatch directory. Just remove the first condition &quot;num~=this.current_index &amp;&amp;&quot;.</p>\r\n<p>Isabelle</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "11148": "",
    "11158": "",
    "11225": ""
  },
  "source": "meta"
}