Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

udpipe_load_model

Load an UDPipe model


Description

Load an UDPipe model so that it can be use in udpipe_annotate

Usage

udpipe_load_model(file)

Arguments

file

full path to the model or the value returned by a call to udpipe_download_model

Value

An object of class udpipe_model which is a list with 2 elements

  • file: The path to the model as provided by file

  • model: An Rcpp-generated pointer to the loaded model which can be used in udpipe_annotate

References

See Also

Examples

## Not run: 
x <- udpipe_download_model(language = "dutch-lassysmall")
x$file_model
ud_english <- udpipe_load_model(x$file_model)

x <- udpipe_download_model(language = "english")
x$file_model
ud_english <- udpipe_load_model(x$file_model)

x <- udpipe_download_model(language = "hebrew")
x$file_model
ud_hebrew <- udpipe_load_model(x$file_model)

## End(Not run)


x <- udpipe_download_model(language = "dutch-lassysmall", model_dir = tempdir())
x$file_model
if(!x$download_failed){
  ud_dutch <- udpipe_load_model(x$file_model)
}

## cleanup for CRAN
if(file.exists(x$file_model)) file.remove(x$file_model)

udpipe

Tokenization, Parts of Speech Tagging, Lemmatization and Dependency Parsing with the 'UDPipe' 'NLP' Toolkit

v0.8.5
MPL-2.0
Authors
Jan Wijffels [aut, cre, cph], BNOSAC [cph], Institute of Formal and Applied Linguistics, Faculty of Mathematics and Physics, Charles University in Prague, Czech Republic [cph], Milan Straka [ctb, cph], Jana Straková [ctb, cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.