question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Permission denied error while using pycrfsuite in rasa_nlu

See original GitHub issue

Hello,

I am trying to execute the below commands as given in http://rasa-nlu.readthedocs.io/en/latest/python.html but getting an error as permission denied as shown below:

`>>> trainer.train(training_data) Traceback (most recent call last): File “<stdin>”, line 1, in <module> File “C:\Users\shuvayan.das\AppData\Local\Continuum\Anaconda3.3\lib\site-packa ges\rasa_nlu\model.py”, line 157, in train updates = component.train(*args) File “C:\Users\shuvayan.das\AppData\Local\Continuum\Anaconda3.3\lib\site-packa ges\rasa_nlu\extractors\crf_entity_extractor.py”, line 80, in train self._train_model(dataset) File “C:\Users\shuvayan.das\AppData\Local\Continuum\Anaconda3.3\lib\site-packa ges\rasa_nlu\extractors\crf_entity_extractor.py”, line 308, in _train_model self.ent_tagger.open(self.crf_file.name) File “pycrfsuite/_pycrfsuite.pyx”, line 571, in pycrfsuite._pycrfsuite.Tagger. open (pycrfsuite/_pycrfsuite.cpp:7731) File “pycrfsuite/_pycrfsuite.pyx”, line 717, in pycrfsuite._pycrfsuite.Tagger. _check_model (pycrfsuite/_pycrfsuite.cpp:10037) PermissionError: [Errno 13] Permission denied: ‘C:\Users\shuvayan.das\AppData \Local\Temp\tmpy84meugg’

`

Please help in resolving this. I am using windows here.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
kmikecommented, May 11, 2017

Hey,

I believe it is a bug in rasa-nlu library - it uses NamedTemporaryFIle, and this may cause problems on Windows - see http://stackoverflow.com/questions/18903069/how-can-i-read-namedtemporaryfile-in-python. This can’t be fixed in python-crfsuite; python-crfsuite just tries to save a file to a specified path, or open a file at a specified path; it is up to the caller to make sure destination is writable or readable.

I suggest to open an issue at rasa-nlu bug tracker. Instead of managing these temporary files manually it may be easier to use https://github.com/TeamHG-Memex/sklearn-crfsuite which handles temporary files automatically; with sklearn-crfsuite pickle or joblib can be used for persistence.

1reaction
kmikecommented, May 11, 2017

No downsides. Well, maybe only that sklearn-crfsuite brings you a couple of new pure-python dependencies (python-tabulate, tqdm) which are installed automatically along with sklearn-crfsuite. scikit-learn itself is not required for the basic use.

Read more comments on GitHub >

github_iconTop Results From Across the Web

pip install failing with: OSError: [Errno 13] Permission denied ...
I got an error like this sudo:pip: command not found on my aws ec2 instance when running this command. Please help. – user3768495....
Read more >
Permission denied when using Docker - Rasa Open Source
I'm want to use interactive command but it return me this error : [root@wqya1726 chatbot_rasa]# rasa interactive Nothing changed.
Read more >
Permission denied while opening a file in python
Though I changed the permissions of log. How to Fix Access Denied Folder and Files Errors on Windows 10, 8, 7 SUBSCRIBE for...
Read more >
Simple index - piwheels
... albatradis uw-saml odoo10-addon-account-invoice-report-ddt-group kornia-rs python-sample-package-with-data-aitirga placavehiculos-pkg-aquintero535 ...
Read more >
guli package permission denied problem - Raspberry Pi Forums
Looks that your program tries to write to a file where permission is denied: '/usr/local/lib/python3.7/dist-packages/guli/data.json' On my ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found