Search code examples
ibm-watsonwatsonvisual-recognition

Error 400 when Creating Custom Classifier in Watson Visual Recognition


I am currently facing a problem to create my own classfiers. I already tried to build a NodeJS application and also create it using IBM's demo, but everytime I submit my ZIP folders to be created, I recieve the following error message:

Cannot execute learning task.  : need at least 2 _positive_examples fields,  (or 1 _positive_examples and 1 negative_examples field) to train a classifier. null specified.

However, when I tried to use the IBM Demo webapp using the .zip they provide (husky, beagle and cats.zip files) the classifier is successfully createdi

I have currently 2 zips (1 positive and 1 negative) each containing 50 files named from 1.jpg to 50.jpg.

Have any of you guys ever gone through this issue and found a way to handle it?

Thanks for the attention.

Best regards, Enrico Bergamo


Solution

  • As per the discussion on the DeveloperWorks Forum ( https://developer.ibm.com/answers/questions/377690/error-400-when-trying-to-create-a-custom-classifie/ ), Your zip files are not really zips. It looks like all you have done is name your folder positive.zip.

    Right click on each of the folders in turn and select create zip or compress as zip.