{
  "id": 1221,
  "title": "Questions about Sample Code",
  "url": "/competitions/GestureChallenge/discussion/1221",
  "author_name": "",
  "post_date": "2012-01-04T19:01:18.210Z",
  "votes": null,
  "comment_count": 9,
  "views": 3532,
  "content": "<p><strong><span style=\"text-decoration:underline\">Main.m</span></strong></p>\r\n<p>Line 39:&nbsp;</p>\r\n<p>truth_dir &nbsp; = []; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; % Where the missing truth labels are...</p>\r\n<p>Not sure what this is refering to. Is this the actual labels for the data?&nbsp;</p>\r\n<p>&nbsp;</p>\r\n<p>Line 72:&nbsp;</p>\r\n<p>recog_options={'test_on_training_data=1', 'movie_type=''K'''};</p>\r\n<p>Are these parameters/assignment to the variables in the recog_template?</p>\r\n<p>&nbsp;</p>\r\n<p>Line 126- Line 129:</p>\r\n<pre>% Load training and test data<br>        dt=sprintf('%s/%s', data_dir, set_name);<br>        if ~exist(dt),fprintf('No data for %s\\n', set_name); continue; end<br>        D=databatch(dt, truth_dir);</pre>\r\n<p>Does it have both training and testing data for valid data set provided? I thought for the valid data the testing is done when you submit your csv file online?&nbsp;</p>\r\n<p>&nbsp;</p>\r\n<p>Line 134-138:</p>\r\n<pre>% Split the data into training and test set<br>        Dtr=subset(D, 1:D.vocabulary_size);<br>        Dte=subset(D, D.vocabulary_size&#43;1:length(D));<br>        TrLabelNum(i)=labelnum(Dtr);<br>        TeLabelNum(i)=labelnum(Dte);</pre>\r\n<pre>Why would you split the data since you are already providing it seperate training data and testing data? For the valid data isn't the testing done when you submit csv file online? So why would we need to split data into training and testing data set? </pre>\r\n<p>Line 144-146:</p>\r\n<pre>        % Train a trivial model<br>        tic<br>        [tr_resu, mymodel]=train(recog_template(recog_options), Dtr);</pre>\r\n<pre>What does &quot;tic&quot; mean? So we basically want to change the recog_template code to change the model?</pre>\r\n<pre>&nbsp;</pre>\r\n<pre>&nbsp;</pre>\r\n<pre>MAY HAVE MORE QUESTIONS ABOUT REMAINING FILES....</pre>\r\n<pre>Thanks!</pre>",
  "messages": [
    {
      "id": "7660",
      "postDate": "01/04/2012 19:01:18",
      "content": "<p><strong><span style=\"text-decoration:underline\">Main.m</span></strong></p>\r\n<p>Line 39:&nbsp;</p>\r\n<p>truth_dir &nbsp; = []; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; % Where the missing truth labels are...</p>\r\n<p>Not sure what this is refering to. Is this the actual labels for the data?&nbsp;</p>\r\n<p>&nbsp;</p>\r\n<p>Line 72:&nbsp;</p>\r\n<p>recog_options={'test_on_training_data=1', 'movie_type=''K'''};</p>\r\n<p>Are these parameters/assignment to the variables in the recog_template?</p>\r\n<p>&nbsp;</p>\r\n<p>Line 126- Line 129:</p>\r\n<pre>% Load training and test data<br>        dt=sprintf('%s/%s', data_dir, set_name);<br>        if ~exist(dt),fprintf('No data for %s\\n', set_name); continue; end<br>        D=databatch(dt, truth_dir);</pre>\r\n<p>Does it have both training and testing data for valid data set provided? I thought for the valid data the testing is done when you submit your csv file online?&nbsp;</p>\r\n<p>&nbsp;</p>\r\n<p>Line 134-138:</p>\r\n<pre>% Split the data into training and test set<br>        Dtr=subset(D, 1:D.vocabulary_size);<br>        Dte=subset(D, D.vocabulary_size&#43;1:length(D));<br>        TrLabelNum(i)=labelnum(Dtr);<br>        TeLabelNum(i)=labelnum(Dte);</pre>\r\n<pre>Why would you split the data since you are already providing it seperate training data and testing data? For the valid data isn't the testing done when you submit csv file online? So why would we need to split data into training and testing data set? </pre>\r\n<p>Line 144-146:</p>\r\n<pre>        % Train a trivial model<br>        tic<br>        [tr_resu, mymodel]=train(recog_template(recog_options), Dtr);</pre>\r\n<pre>What does &quot;tic&quot; mean? So we basically want to change the recog_template code to change the model?</pre>\r\n<pre>&nbsp;</pre>\r\n<pre>&nbsp;</pre>\r\n<pre>MAY HAVE MORE QUESTIONS ABOUT REMAINING FILES....</pre>\r\n<pre>Thanks!</pre>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7661",
      "postDate": "01/04/2012 19:19:55",
      "content": "<p>tic is timing function = &quot;start clock&quot;<br>\r\nused in pairs with toc (returns elapsed time)</p>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7662",
      "postDate": "01/04/2012 19:58:49",
      "content": "<p><strong>recog_template.m</strong></p>\r\n<p>Line 6-Line 7:</p>\r\n<pre>% This is an object similar to a Spider object<br>% http://www.kyb.mpg.de/bs/people/spider/</pre>\r\n<pre>Is this a addition to matlab? Basically a package which we can download since it has machine learning algorithms? </pre>\r\n<pre>&nbsp;</pre>\r\n<pre>Line 27-Line 31:</pre>\r\n<pre>        function a = recog_template(hyper) <br>            % Evaluate hyper-parameters entered with the syntax of the<br>            % Spider http://www.kyb.mpg.de/bs/people/spider/<br>            eval_hyper;<br>        end  </pre>\r\n<pre>What is eval_hyper? I was unable to find any reference to this using the link and it isn't reference in any of the other .m files? </pre>\r\n<pre>Thanks!</pre>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7682",
      "postDate": "01/05/2012 07:09:48",
      "content": "<p>Nvm think I understand what is going on. </p>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7784",
      "postDate": "01/09/2012 05:11:35",
      "content": "<p>eval_hyper.m(Line 77- Line 78)</p>\r\n<p>%% --------------- add algorithm calls -------------------------<br>\r\n%% -------------------------------------------------------------</p>\r\n<p>Is this where we are supposed to call any algorithms we implement?</p>\r\n<p>Thanks!</p>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7789",
      "postDate": "01/09/2012 07:15:24",
      "content": "<p>[quote=Aniket;7662]</p>\r\n<pre>Line 27-Line 31:</pre>\r\n<pre>        function a = recog_template(hyper) <br>            % Evaluate hyper-parameters entered with the syntax of the<br>            % Spider http://www.kyb.mpg.de/bs/people/spider/<br>            eval_hyper;<br>        end  </pre>\r\n<pre>What is eval_hyper? I was unable to find any reference to this using the link and it isn't reference in any of the other .m files? </pre>\r\n<pre>Thanks!</pre>\r\n<p>[/quote]</p>\r\n<p>&nbsp;</p>\r\n<p>eval_hyper is a script I borrowed from the Spider package. It allows you to conveniently not specity all the arguments you pass to the object recog_template.</p>\r\n<p>So when you construct the object&nbsp;<span class=\"x_Apple-style-span\" style=\"white-space:pre\"><span class=\"x_pln\">recog_template</span><span class=\"x_pun\">(</span><span class=\"x_pln\">recog_options</span><span class=\"x_pun\">),\r\n</span></span><span class=\"x_Apple-style-span\" style=\"white-space:pre\">recog_option can be:</span></p>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'test_on_training_data=1', 'movie_type=''K'''};<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'movie_type=''K'''};<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'test_on_training_data=1'};<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'movie_type=''K''', </span>'test_on_training_data=1'};</pre>\r\n<pre class=\"x_prettyprint\">You can use that script at your convenience to allow objects you contruct to use this flexibe syntax to specify parameters.</pre>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7790",
      "postDate": "01/09/2012 07:18:03",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p><strong><span style=\"text-decoration:underline\">Main.m</span></strong></p>\r\n<p>Line 39:&nbsp;</p>\r\n<p>truth_dir &nbsp; = []; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; % Where the missing truth labels are...</p>\r\n<p>Not sure what this is refering to. Is this the actual labels for the data?&nbsp;</p>\r\n<p>[/quote]</p>\r\n<p>We do not provide the truth labels for th validation data at the moment. But, when we release them, you will be able to point to the directory where you store them. We just made provisions in the code for that.</p>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7791",
      "postDate": "01/09/2012 07:21:07",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p>&nbsp;</p>\r\n<p>Line 72:&nbsp;</p>\r\n<p>recog_options={'test_on_training_data=1', 'movie_type=''K'''};</p>\r\n<p>Are these parameters/assignment to the variables in the recog_template?</p>\r\n<p>&nbsp;</p>\r\n<p>[/quote]</p>\r\n<p>This is just provided as an example of things you can do.&nbsp;</p>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">'test_on_training_data=1', means that you test on the training examples (not necessary for submissions, you can skip it to save time)</span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">&nbsp;'movie_type=''K''' means that the depth images are used. &nbsp;'movie_type=''M''' means that the RGB images are used.<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">To win, you probably want to create an algorithm that uses both RGB and depth.</span></pre>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7792",
      "postDate": "01/09/2012 07:24:02",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p>Line 126- Line 129:</p>\r\n<pre>% Load training and test data<br>        dt=sprintf('%s/%s', data_dir, set_name);<br>        if ~exist(dt),fprintf('No data for %s\\n', set_name); continue; end<br>        D=databatch(dt, truth_dir);</pre>\r\n<p>Does it have both training and testing data for valid data set provided? I thought for the valid data the testing is done when you submit your csv file online?&nbsp;</p>\r\n<p>[/quote]</p>\r\n<p>Yes, the testing is done on validation data when you submit the files. Since we (the organizers) have also the truth labels for the validation examples, we tested the code with the labels of the validation data to check everything, this is why this is there\r\n in the sample code.</p>",
      "rawMarkdown": "",
      "votes": null
    },
    {
      "id": "7793",
      "postDate": "01/09/2012 07:28:45",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p>Line 134-138:</p>\r\n<pre>% Split the data into training and test set<br>        Dtr=subset(D, 1:D.vocabulary_size);<br>        Dte=subset(D, D.vocabulary_size&#43;1:length(D));<br>        TrLabelNum(i)=labelnum(Dtr);<br>        TeLabelNum(i)=labelnum(Dte);</pre>\r\n<pre>Why would you split the data since you are already providing it seperate training data and testing data? For the valid data isn't the testing done when you submit csv file online? So why would we need to split data into training and testing data set? </pre>\r\n<p>[/quote]</p>\r\n<p>All batches are organized such that the first N examples can be used for training. N is the size of the lexicon of the batch. The first N examples cover all the classes and allow you to do one-shot-learning in that batch.&nbsp;</p>\r\n<p>Do not confuse the development data with &quot;training data&quot; and the validation data with &quot;test data&quot;. Each batch has traning and test data. The difference between the development data and the validation data is that for development data you have ALL the labels\r\n and are free to split the data in another way than the one we made provisions for. For the validation data, we gave you only the training labels. You must predict the test labels.</p>\r\n<p>Each batch is a separate task with training and test data.</p>",
      "rawMarkdown": "",
      "votes": null
    }
  ],
  "comments": [
    {
      "id": 7661,
      "author_name": "ccccat",
      "author_url": "",
      "post_date": "01/04/2012 19:19:55",
      "content": "<p>tic is timing function = &quot;start clock&quot;<br>\r\nused in pairs with toc (returns elapsed time)</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7662,
      "author_name": "",
      "author_url": "",
      "post_date": "01/04/2012 19:58:49",
      "content": "<p><strong>recog_template.m</strong></p>\r\n<p>Line 6-Line 7:</p>\r\n<pre>% This is an object similar to a Spider object<br>% http://www.kyb.mpg.de/bs/people/spider/</pre>\r\n<pre>Is this a addition to matlab? Basically a package which we can download since it has machine learning algorithms? </pre>\r\n<pre>&nbsp;</pre>\r\n<pre>Line 27-Line 31:</pre>\r\n<pre>        function a = recog_template(hyper) <br>            % Evaluate hyper-parameters entered with the syntax of the<br>            % Spider http://www.kyb.mpg.de/bs/people/spider/<br>            eval_hyper;<br>        end  </pre>\r\n<pre>What is eval_hyper? I was unable to find any reference to this using the link and it isn't reference in any of the other .m files? </pre>\r\n<pre>Thanks!</pre>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7682,
      "author_name": "",
      "author_url": "",
      "post_date": "01/05/2012 07:09:48",
      "content": "<p>Nvm think I understand what is going on. </p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7784,
      "author_name": "",
      "author_url": "",
      "post_date": "01/09/2012 05:11:35",
      "content": "<p>eval_hyper.m(Line 77- Line 78)</p>\r\n<p>%% --------------- add algorithm calls -------------------------<br>\r\n%% -------------------------------------------------------------</p>\r\n<p>Is this where we are supposed to call any algorithms we implement?</p>\r\n<p>Thanks!</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7789,
      "author_name": "iguyon",
      "author_url": "",
      "post_date": "01/09/2012 07:15:24",
      "content": "<p>[quote=Aniket;7662]</p>\r\n<pre>Line 27-Line 31:</pre>\r\n<pre>        function a = recog_template(hyper) <br>            % Evaluate hyper-parameters entered with the syntax of the<br>            % Spider http://www.kyb.mpg.de/bs/people/spider/<br>            eval_hyper;<br>        end  </pre>\r\n<pre>What is eval_hyper? I was unable to find any reference to this using the link and it isn't reference in any of the other .m files? </pre>\r\n<pre>Thanks!</pre>\r\n<p>[/quote]</p>\r\n<p>&nbsp;</p>\r\n<p>eval_hyper is a script I borrowed from the Spider package. It allows you to conveniently not specity all the arguments you pass to the object recog_template.</p>\r\n<p>So when you construct the object&nbsp;<span class=\"x_Apple-style-span\" style=\"white-space:pre\"><span class=\"x_pln\">recog_template</span><span class=\"x_pun\">(</span><span class=\"x_pln\">recog_options</span><span class=\"x_pun\">),\r\n</span></span><span class=\"x_Apple-style-span\" style=\"white-space:pre\">recog_option can be:</span></p>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'test_on_training_data=1', 'movie_type=''K'''};<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'movie_type=''K'''};<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'test_on_training_data=1'};<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">recog_options={'movie_type=''K''', </span>'test_on_training_data=1'};</pre>\r\n<pre class=\"x_prettyprint\">You can use that script at your convenience to allow objects you contruct to use this flexibe syntax to specify parameters.</pre>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7790,
      "author_name": "iguyon",
      "author_url": "",
      "post_date": "01/09/2012 07:18:03",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p><strong><span style=\"text-decoration:underline\">Main.m</span></strong></p>\r\n<p>Line 39:&nbsp;</p>\r\n<p>truth_dir &nbsp; = []; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; % Where the missing truth labels are...</p>\r\n<p>Not sure what this is refering to. Is this the actual labels for the data?&nbsp;</p>\r\n<p>[/quote]</p>\r\n<p>We do not provide the truth labels for th validation data at the moment. But, when we release them, you will be able to point to the directory where you store them. We just made provisions in the code for that.</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7791,
      "author_name": "iguyon",
      "author_url": "",
      "post_date": "01/09/2012 07:21:07",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p>&nbsp;</p>\r\n<p>Line 72:&nbsp;</p>\r\n<p>recog_options={'test_on_training_data=1', 'movie_type=''K'''};</p>\r\n<p>Are these parameters/assignment to the variables in the recog_template?</p>\r\n<p>&nbsp;</p>\r\n<p>[/quote]</p>\r\n<p>This is just provided as an example of things you can do.&nbsp;</p>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">'test_on_training_data=1', means that you test on the training examples (not necessary for submissions, you can skip it to save time)</span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">&nbsp;'movie_type=''K''' means that the depth images are used. &nbsp;'movie_type=''M''' means that the RGB images are used.<br></span></pre>\r\n<pre class=\"x_prettyprint\"><span class=\"x_pun\">To win, you probably want to create an algorithm that uses both RGB and depth.</span></pre>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7792,
      "author_name": "iguyon",
      "author_url": "",
      "post_date": "01/09/2012 07:24:02",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p>Line 126- Line 129:</p>\r\n<pre>% Load training and test data<br>        dt=sprintf('%s/%s', data_dir, set_name);<br>        if ~exist(dt),fprintf('No data for %s\\n', set_name); continue; end<br>        D=databatch(dt, truth_dir);</pre>\r\n<p>Does it have both training and testing data for valid data set provided? I thought for the valid data the testing is done when you submit your csv file online?&nbsp;</p>\r\n<p>[/quote]</p>\r\n<p>Yes, the testing is done on validation data when you submit the files. Since we (the organizers) have also the truth labels for the validation examples, we tested the code with the labels of the validation data to check everything, this is why this is there\r\n in the sample code.</p>",
      "votes": null,
      "replies": []
    },
    {
      "id": 7793,
      "author_name": "iguyon",
      "author_url": "",
      "post_date": "01/09/2012 07:28:45",
      "content": "<p>[quote=Aniket;7660]</p>\r\n<p>Line 134-138:</p>\r\n<pre>% Split the data into training and test set<br>        Dtr=subset(D, 1:D.vocabulary_size);<br>        Dte=subset(D, D.vocabulary_size&#43;1:length(D));<br>        TrLabelNum(i)=labelnum(Dtr);<br>        TeLabelNum(i)=labelnum(Dte);</pre>\r\n<pre>Why would you split the data since you are already providing it seperate training data and testing data? For the valid data isn't the testing done when you submit csv file online? So why would we need to split data into training and testing data set? </pre>\r\n<p>[/quote]</p>\r\n<p>All batches are organized such that the first N examples can be used for training. N is the size of the lexicon of the batch. The first N examples cover all the classes and allow you to do one-shot-learning in that batch.&nbsp;</p>\r\n<p>Do not confuse the development data with &quot;training data&quot; and the validation data with &quot;test data&quot;. Each batch has traning and test data. The difference between the development data and the validation data is that for development data you have ALL the labels\r\n and are free to split the data in another way than the one we made provisions for. For the validation data, we gave you only the training labels. You must predict the test labels.</p>\r\n<p>Each batch is a separate task with training and test data.</p>",
      "votes": null,
      "replies": []
    }
  ],
  "raw_markdown_by_id": {
    "7660": "",
    "7661": "",
    "7662": "",
    "7682": "",
    "7784": "",
    "7789": "",
    "7790": "",
    "7791": "",
    "7792": "",
    "7793": ""
  },
  "source": "meta"
}