MCPcopy Create free account
hub / github.com/apple/coremltools / addStringLabels

Function addStringLabels

mlmodel/tests/KNNValidatorTests.cpp:89–99  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

87 }
88
89 void addStringLabels(Specification::KNearestNeighborsClassifier* nnModel) {
90
91 nnModel->mutable_stringclasslabels()->add_vector(std::string("zero"));
92 nnModel->mutable_stringclasslabels()->add_vector(std::string("zero"));
93 nnModel->mutable_stringclasslabels()->add_vector(std::string("zero"));
94
95 nnModel->mutable_stringclasslabels()->add_vector(std::string("zero"));
96 nnModel->mutable_stringclasslabels()->add_vector(std::string("zero"));
97 nnModel->mutable_stringclasslabels()->add_vector(std::string("zero"));
98
99 }
100
101 // Sets numberOfNeighbors range bounds to 1-10 if forRange is true, else numberOfNeighbors set
102 // containing { numberOfNeighbors, 1, 2, 4, 8 }.

Calls

no outgoing calls

Tested by

no test coverage detected