ContextSpellCheckerModel Error #392
Unanswered
matt-song27
asked this question in
Q&A
Replies: 1 comment 1 reply
-
@maziyarpanahi Could you please help on this issue? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello JohnSnowLabs,
This is Matt. I would like to have a question about using ContextSpellCheckerModel of SparkNLP.
Please see the below for Environments, Code, and the Error.
Thank you!!
Environments
OS: Ubuntu 20.04.2 LTS WSL on Windows 10
Spark Version: 3.0.2
pyspark version: 3.0.2
Spark NLP Version: 3.2.2
Spark JSL Version: 3.2.2
openjdk version "1.8.0_292"
OpenJDK Runtime Environment (build 1.8.0_292-8u292-b10-0ubuntu1~20.04-b10)
OpenJDK 64-Bit Server VM (build 25.292-b10, mixed mode)
Code
from pyspark.ml import Pipeline
from pyspark.sql import SparkSession
import pyspark.sql.functions as F
import sparknlp
from sparknlp.annotator import *
from sparknlp_jsl.annotator import *
from sparknlp.base import *
import sparknlp_jsl
spark = sparknlp_jsl.start(license_keys['SECRET'])
documentAssembler = DocumentAssembler()
.setInputCol("text")
.setOutputCol("document")
tokenizer = RecursiveTokenizer()
.setInputCols(["document"])
.setOutputCol("token")
.setPrefixes([""", "(", "[", "\n"])
.setSuffixes([".", ",", "?", ")","!", "'s"])
spellModel = ContextSpellCheckerModel
.pretrained('spellcheck_clinical', 'en', 'clinical/models')
.setInputCols("token")
.setOutputCol("checked")
Error
Beta Was this translation helpful? Give feedback.
All reactions