Skip to content

Commit

Permalink
Updated JPMML-Evaluator dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
vruusmann committed Jan 1, 2025
1 parent ff4172b commit 5b63898
Show file tree
Hide file tree
Showing 10 changed files with 8 additions and 21 deletions.
8 changes: 4 additions & 4 deletions inst/java/classpath.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ jakarta.activation-2.0.1.jar
jakarta.xml.bind-api-3.0.1.jar
jaxb-core-3.0.2.jar
jaxb-runtime-3.0.2.jar
pmml-evaluator-1.6.8.jar
pmml-evaluator-metro-1.6.8.jar
pmml-model-1.6.8.jar
pmml-model-metro-1.6.8.jar
pmml-evaluator-1.6.9.jar
pmml-evaluator-metro-1.6.9.jar
pmml-model-1.6.9.jar
pmml-model-metro-1.6.9.jar
pmml-rexp-1.6.4-minified.jar
Binary file modified inst/java/jpmml-evaluator-r-1.0-SNAPSHOT.jar
Binary file not shown.
Binary file not shown.
Binary file removed inst/java/pmml-evaluator-metro-1.6.8.jar
Binary file not shown.
Binary file added inst/java/pmml-evaluator-metro-1.6.9.jar
Binary file not shown.
Binary file removed inst/java/pmml-model-1.6.8.jar
Binary file not shown.
Binary file added inst/java/pmml-model-1.6.9.jar
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>org.jpmml</groupId>
<artifactId>jpmml-evaluator</artifactId>
<version>1.6.8</version>
<version>1.6.9</version>
</parent>

<groupId>org.jpmml</groupId>
Expand Down
19 changes: 3 additions & 16 deletions src/main/java/org/jpmml/evaluator/rexp/RExpUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -199,10 +199,11 @@ private RGenericVector formatDataFrame(Table table, boolean stringsAsFactors){
vectors.add(vector);
}

List<Exception> exceptions = table.getExceptions();
List<String> errors = null;

if(containsNonNull(exceptions)){
if(table.hasExceptions()){
List<Exception> exceptions = table.getExceptions();

errors = exceptions.stream()
.map(exception -> (exception != null ? exception.toString() : null))
.collect(Collectors.toList());
Expand Down Expand Up @@ -275,20 +276,6 @@ private RVector<?> createVector(List<?> values){
}
}

static
private <E> boolean containsNonNull(List<E> values){

for(int i = 0; i < values.size(); i++){
E value = values.get(i);

if(value != null){
return true;
}
}

return false;
}

static
private RExp unserialize(byte[] bytes) throws IOException {

Expand Down

0 comments on commit 5b63898

Please sign in to comment.