aymara / lima-python

MIT License
3 stars 0 forks source link

Remove internal debug messages from python output #3

Closed kleag closed 2 years ago

kleag commented 2 years ago

Currently, instantiating lima causes these messages:

>>> l = aymara.lima.Lima("ud-fra")
No such param 'LinguisticData[SyntacticAnalysis][CompoundTensesDefFile]' /home/gael/.virtualenvs/lima/lib/python3.8/site-packages/aymaralima/config/lima-common-ud.xml
No such param 'LinguisticData[SyntacticAnalysis][CompoundTensesDefFile]' /home/gael/.virtualenvs/lima/lib/python3.8/site-packages/aymaralima/config/lima-common-ud.xml
 : Common::Processors : 2022-01-07T17:59:53.977 ERROR 0x2956510 no pipeline ' main ' for media  ud-eng 
 : Common::Processors : 2022-01-07T17:59:53.977 ERROR 0x2956510 no pipeline ' main ' for media  ud-fra 
 : LP::TensorFlowMorphoSyntax : 2022-01-07T17:59:53.984 ERROR 0x2956510 TensorFlowLemmatizer::load_config config file " "/home/gael/.local/share//lima/resources///TensorFlowMorphoSyntax/ud/morphosyntax-fra.conf" " missing param main_alphabet. 
 : LP::TensorFlowMorphoSyntax : 2022-01-07T17:59:53.984 ERROR 0x2956510 TensorFlowLemmatizer::load_config config file " "/home/gael/.local/share//lima/resources///TensorFlowMorphoSyntax/ud/morphosyntax-fra.conf" " missing param feat_order. 
 : LP::TensorFlowMorphoSyntax : 2022-01-07T17:59:53.984 ERROR 0x2956510 TensorFlowLemmatizer::load_config config file " "/home/gael/.local/share//lima/resources///TensorFlowMorphoSyntax/ud/morphosyntax-fra.conf" " missing param feat_deps. 
 : FilesReporting : 2022-01-07T17:59:56.403  WARN 0x2956510 findFileInPaths no ' "/TensorFlowLemmatizer/ud/lemmatizer-fra.cache" ' found in ' "/home/gael/.local/share//lima/resources/:/usr//share/apps/lima/resources:/home/gael/.virtualenvs/lima/lib/python3.8/site-packages/aymaralima/resources" ' separated by ' ':' ' 
 : LP::TensorFlowLemmatizer : 2022-01-07T17:59:56.403 ERROR 0x2956510 ERROR: TensorFlowLemmatizerPrivate::load_config: "dont_lemmatize" isn't defined. 
 : LP::TensorFlowLemmatizer : 2022-01-07T17:59:56.403 ERROR 0x2956510 TensorFlowLemmatizer::load_config config file " "/home/gael/.local/share//lima/resources///TensorFlowLemmatizer/ud/lemmatizer-fra.conf" " missing param main_alphabet. 
 : LP::TensorFlowLemmatizer : 2022-01-07T17:59:56.403 ERROR 0x2956510 TensorFlowLemmatizer::load_config config file " "/home/gael/.local/share//lima/resources///TensorFlowLemmatizer/ud/lemmatizer-fra.conf" " missing param special_chars. 

This is problematic for users.

kleag commented 2 years ago

This is mainly done. Most of the messages have been moved to info or debug channels.