use of ml.shifu.shifu.core.processor.CreateModelProcessor in project shifu by ShifuML.
the class ShifuCLI method createNewModel.
/*
* Create new model - create directory and ModelConfig for the model
*/
public static int createNewModel(String modelSetName, String modelType, String description) throws Exception {
ALGORITHM modelAlg = null;
if (modelType != null) {
for (ALGORITHM alg : ALGORITHM.values()) {
if (alg.name().equalsIgnoreCase(modelType.trim())) {
modelAlg = alg;
}
}
} else {
modelAlg = ALGORITHM.NN;
}
if (modelAlg == null) {
log.error("Unsupported algirithm - {}", modelType);
return 2;
}
CreateModelProcessor p = new CreateModelProcessor(modelSetName, modelAlg, description);
return p.run();
}
Aggregations