Peratham / semanticvectors

Automatically exported from code.google.com/p/semanticvectors
Other
0 stars 0 forks source link

contentsfields array #58

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I would like to create a semantic space with multiple contents fields.
As contentsfields in the class Flags is a String array I create one :
1. String[] contentsfields={"Catalogue_title","Catalogue_contents"};
2. String BuildSpaceArguments = "-dimension " + dimensions
                    + " -seedlength " + seedLength
                    + " -minfrequency " + minFreq
                    + " -trainingcycles " + trainingCycles
                    + " -contentsfields " + contentsfields
                    + " -docindexing " + docsIncremental + " " + PATH_TO_LUCENE_INDEX;

What is the expected output? 
The expected output is a well structured semantic space but it created an empty 
one because the Flags method parseCommandLineFlags can't deal with a string 
array

I'm using semanticvectors 3.2 but I think it's the same with the 3.4 version

Original issue reported on code.google.com by barh...@gmail.com on 3 Apr 2012 at 3:30

GoogleCodeExporter commented 9 years ago
Sorry not to have noticed this for so long.

FlagConfig.getFlagConfig takes a string and parses the arguments, a few into 
string arrays. So in this case you should just need to replace the array 
declaration with

String contentsfields = "Catalogue_title,Catalogue_contents";

and the rest should work.

Original comment by dwidd...@gmail.com on 22 Oct 2013 at 2:51

GoogleCodeExporter commented 9 years ago

Original comment by dwidd...@gmail.com on 22 Oct 2013 at 2:51