Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Results difference between command-line CRFsuite vs Python CRFsuite #124

Open
UAmsterdam opened this issue Feb 12, 2024 · 0 comments
Open

Comments

@UAmsterdam
Copy link

UAmsterdam commented Feb 12, 2024

I was trying to replicate a code which was using CRFsuite (Command line version) for training a model. Below is the command:

"crfsuite learn -a pa -p c=0.1 -p type=2 -p max_iterations=100 -m model.crfsuite sample_data"

Then I was trying to replicate it using python wrapper of CRFsuite like this on same dataset:

"crf = CRF(algorithm="pa",c=0.1, max_iterations=100, pa_type=2, verbose=True)
crf.fit(X_train, y_train)"

I am not getting the same results:

From the command line I am getting
"Precision: 0.9491228053524161, Recall: 0.9107744092411205, F1: 0.9295527632204716"

However, from the python version I am getting:

"Precision: 0.9633401202375965, Recall: 0.7962962949557302, F1: 0.8718889038207067"

Does anyone else have also faced this challenge or know about these kind of issues?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant