Hi,

I am using the Solr LTR in Solr 7.4.0, and I am trying to train an example
learning model using LIBLINEAR.

When I tried to run the code from train_and_upload_demo_model.py , I can
only train one feature at a time. If I put more than one features, then I
will get the following error

Traceback (most recent call last):

  File "train_and_upload_demo_model.py", line 182, in <module>

    sys.exit(main())

  File "train_and_upload_demo_model.py", line 169, in main


formatter.processQueryDocFeatureVector(fvGenerator,config["trainingFile"]);

  File
"/cygdrive/c/Users/edwin_000/Desktop/edwin/edm-7.4.0/contrib/ltr/myModel/libsvm_formatter.py",
line 25, in processQueryDocFeatureVector

    curListOfFv.append((relevance,self._makeFeaturesMap(featureVector)))

  File
"/cygdrive/c/Users/edwin_000/Desktop/edwin/edm-7.4.0/contrib/ltr/myModel/libsvm_formatter.py",
line 35, in _makeFeaturesMap

    featName,featValue = keyValuePairStr.split(":");

ValueError: too many values to unpack


Is there any way that we can do so that we can train 2 or more features at
the same time?

Regards,
Edwin

Reply via email to