science_rcn icon indicating copy to clipboard operation
science_rcn copied to clipboard

How to train using Yahoo or reCaptcha?

Open yeguixin opened this issue 7 years ago • 7 comments

I tried to using the program to train using Yahoo's data provided in your blog, but failed to print the following error message:

INFO:main:Training on 124 images... INFO:main:Testing on 0 images... Traceback (most recent call last): File "science_rcn/run.py", line 230, in parallel=options.parallel) File "science_rcn/run.py", line 95, in run_experiment print "Total test accuracy = {}".format(float(correct) / len(test_results)) ZeroDivisionError: float division by zero

We used the following commond: python science_rcn/run.py --train_size 20 --test_size 20 --parallel

Thanks

yeguixin avatar Nov 02 '17 03:11 yeguixin

Hi Yeguixin,

  • The problem occurs at:

INFO:main:Testing on 0 images...

This means run.py cannot access testing samples. I can reproduce your error by removing folders 0/1/2.. from /testing of the provided MNIST dataset. Therefore, it may be the folder structure, as line 133 def _load_data assumes...

    training/
        0/
        1/
        2/
        ...
    testing/
        0/
        ...

.. inside data/MNIST folder.

This git was made to work with MNIST at first so you have to modify the file(s) yourself if you want to run other datasets. A simple command won't do it in this case.

tbraga14 avatar Nov 24 '17 17:11 tbraga14

I know, you mean you only published the code to recognize MNIST? But I want to konw how to train and test the Yahoo or reCaptcha using the dataset you provided in your paper. Thanks.

yeguixin avatar Nov 25 '17 03:11 yeguixin

Hi Yeguixin,

Sorry, but, just to clarify, it wasn't I who published the code/research. I just meant to help by what I could see in the code directly (run.py, line 2):

Reference implementation of a two-level RCN model for MNIST classification experiments.

I'm afraid I can't provide a better answer than that so you could wait for an official reply from the devs. Thanks.

tbraga14 avatar Nov 28 '17 21:11 tbraga14

I see. Thanks

yeguixin avatar Nov 29 '17 13:11 yeguixin

@yeguixin Have you successfully applied it to the traning and testing in the reCaptcha dataset? if so, could you share you codes with me?

Chong-Jiao avatar Jul 20 '18 07:07 Chong-Jiao

anyone succeed ?

liwanyue123 avatar Jun 11 '19 15:06 liwanyue123

did anyone got it ??

yashy23 avatar Oct 13 '19 21:10 yashy23