Using scipy.stats.stats in django after deployment

后端 未结 2 704
慢半拍i
慢半拍i 2021-01-13 11:30

I am in the process of creating an django-powered (1.3) interface to a package that relies heavily in scipy.stats.stats (scipy version 0.9.0), called ovl . Duri

相关标签:
2条回答
  • 2021-01-13 11:37

    I also encounter this problem when I use scipy.stats in my django application. In django manage.py runsever environment, my app is executed correctly without any problem. But when I deploy the app to apache server with mod_python, I can't enter my app, and the browser keep loading until the time out. After I remove all imported scipy.stats statements in my app, the problem is solved, and I can execute my app in the apache server.

    0 讨论(0)
  • 2021-01-13 12:00

    mod_python used to try using multiple Python interpreters in the same process. mod_wsgi might be doing the same. While this frequently works okay, some extension modules do not support this. scipy.stats is probably importing such an extension module. We have had similar reports on the scipy mailing list concerning scipy.stats under mod_python. Check the mod_wsgi documentation to see if you can configure it such that it does not use multiple interpreters in the same process, or find a different deployment strategy that uses one interpreter per process for the app.

    0 讨论(0)
提交回复
热议问题