jiangxin369 commented on code in PR #193: URL: https://github.com/apache/flink-ml/pull/193#discussion_r1063068991
########## flink-ml-benchmark/src/main/java/org/apache/flink/ml/benchmark/datagenerator/clustering/KMeansModelDataGenerator.java: ########## @@ -55,20 +61,36 @@ public Table[] getData(StreamTableEnvironment tEnv) { InputDataGenerator<?> vectorArrayGenerator = new DenseVectorArrayGenerator(); ReadWriteUtils.updateExistingParams(vectorArrayGenerator, paramMap); vectorArrayGenerator.setNumValues(1); + vectorArrayGenerator.setColNames(new String[] {"centroids"}); Review Comment: Adding the first line `vectorArrayGenerator.setColNames(new String[] {"centroids"});` is because `DenseVectorArrayGenerator` requires `columnNames` is set, otherwise NPE would be thrown. The other changes are to reduce the operation of `toDataStream` and `fromDataStream`, just do the conversion base on `Table`. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org