Comments (5)
java.lang.ClassNotFoundException: org.jpmml.converter.BaseNFeature
Your project is missing a JPMML-Converter library.
did you get this exception before?
No, because I know how to set up my projects correctly.
First, use a proper build manager such as Apache Maven. Second, declare a JPMML-SparkML library dependency, and let the build manager to collect and download JPMML-SparkML transitive dependencies as needed.
You should not be doing this manually. You're not smarter and technically more capable than Apache Maven.
from jpmml-sparkml.
yes, i have used maven, i've checked jpmml-converter library, only 1.4.5 has that class org.jpmml.converter.BaseNFeature, 1.4.10 doesn't, so it gives this error.
from the errors, it seems jpmml-xgboost library is mismatch, i used 1.4.4, which version is suitable for JPMML-SparkM 1.6.6?
thanks
from jpmml-sparkml.
If you want to know which transitive dependencies work with a particular JPMML-SparkML library version, then simply check out the correct tag, and run the mvn dependency:tree
command inside the main module.
For JPMML-SparkML version 1.6.6, do the following:
$ git clone https://github.com/jpmml/jpmml-sparkml.git
$ cd jpmml-sparkml
$ git checkout 1.6.6
$ mvn dependency:tree
The report (omitted some irrelevant parts):
[INFO] +- com.beust:jcommander:jar:1.72:compile
[INFO] +- org.apache.spark:spark-core_2.12:jar:3.0.0:provided
[INFO] +- org.jpmml:jpmml-converter:jar:1.4.10:compile
[INFO] | +- com.google.guava:guava:jar:21.0:compile
[INFO] | +- org.jpmml:pmml-model:jar:1.5.16:compile
[INFO] | | \- org.jpmml:pmml-agent:jar:1.5.16:compile
[INFO] | \- org.jpmml:pmml-model-metro:jar:1.5.16:compile
[INFO] +- junit:junit:jar:4.13.2:test
[INFO] | \- org.hamcrest:hamcrest-core:jar:1.3:test
[INFO] +- org.apache.hadoop:hadoop-client:jar:2.7.4:test
[INFO] \- org.jpmml:pmml-evaluator-testing:jar:1.5.16:test
[INFO] +- org.jpmml:pmml-evaluator:jar:1.5.16:test
[INFO] +- org.jpmml:pmml-evaluator-extension:jar:1.5.16:test
[INFO] +- org.jpmml:pmml-evaluator-kryo:jar:1.5.16:test
[INFO] | +- org.jpmml:pmml-model-kryo:jar:1.5.16:test
[INFO] | | \- com.esotericsoftware:kryo:jar:5.2.2-SNAPSHOT:test (version selected from constraint [5.0.0,))
[INFO] | | \- com.esotericsoftware:reflectasm:jar:1.11.9:test
[INFO] | \- de.javakaffee:kryo-serializers:jar:0.45:test
[INFO] +- org.jpmml:pmml-evaluator-metro:jar:1.5.16:test
[INFO] \- org.jpmml:pmml-evaluator-moxy:jar:1.5.16:test
[INFO] \- org.jpmml:pmml-model-moxy:jar:1.5.16:test
[INFO] \- org.eclipse.persistence:org.eclipse.persistence.moxy:jar:2.7.9:test (version selected from constraint [2.7.0,2.7.9])
[INFO] \- org.eclipse.persistence:org.eclipse.persistence.core:jar:2.7.9:test
[INFO] \- org.eclipse.persistence:org.eclipse.persistence.asm:jar:9.1.0:test
The above report says black-on-white that you MUST use JPMML-Converter 1.4.10.
If you use some other version, then that's your (not JPMML-SparkML) problem.
from jpmml-sparkml.
yes, i have used maven, i've checked jpmml-converter library, only 1.4.5 has that class org.jpmml.converter.BaseNFeature, 1.4.10 doesn't, so it gives this error.
That's a new classpath conflict there, completely separate from the JPMML-SparkML project.
In brief, you're again trying to mix a totally arbitrary version of the JPMML-XGBoost library with JPMML-SparkML and JPMML-Converter library versions.
You need to use an JPMML-XGBoost library version that is compatible with JPMML-Converter version 1.4.10.
from jpmml-sparkml.
After i upgrade jpmml-xgboost version to 1.5.6, that error is fixed and pmml is exported successfuly.
from jpmml-sparkml.
Related Issues (20)
- MultilayerPerceptronClassificationModel IllegalArgumentException("Expected 3 target categories, got 2 target categories"); HOT 1
- How to import the training data schema in libsvm format HOT 15
- Wrong code path for multinomial logistic regression model HOT 1
- Probability column not being found when using it in a stacked model HOT 6
- StringIndexerModelConverter gives java.lang.IllegalArgumentException HOT 4
- Support for custom Java-backed models (eg. factorization machine) HOT 1
- Why One-Hot-Encoding is not visible in PMML? HOT 1
- py4j.protocol.Py4JError: org.jpmml.sparkml.PMMLBuilder does not exist in the JVM HOT 1
- Error with LightGBMClassificationModel HOT 5
- Support for `XGBoostRegressor.missing` property HOT 6
- Troubleshooting XGBoost model performance HOT 17
- Support for Apache Spark 3.3.X HOT 2
- 2.x jars missing from Maven Central HOT 3
- Support for `replace` SQL function HOT 6
- Exception in thread "main" java.lang.NoClassDefFoundError: com/microsoft/azure/synapse/ml/codegen/Wrappable
- java.lang.NoSuchMethodError: org.jpmml.sparkml.SparkMLEncoder.getDataField HOT 1
- Databricks Install HOT 1
- Version v4 is not supported HOT 2
- Cannot convert (partially-) unfitted pipelines HOT 22
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jpmml-sparkml.