Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

from scipy.linalg import _fblas ImportError: DLL load failed: The specified module could not be found.

3,740 views
Skip to first unread message

Mike S

unread,
Feb 8, 2016, 11:22:54 PM2/8/16
to
I have Python 3.4.4 installed on Windows 7, also IPython, scipy, numpy,
statsmodels, and a lot of other modules, and am working through this
tutorial
http://www.analyticsvidhya.com/blog/2016/02/time-series-forecasting-codes-python/

In Ipython notebook I run this code

from statsmodels.tsa.stattools import adfuller
def test_stationarity(timeseries):
#determining rolling statistics
rolmean = pd.rolling_mean(timeseries, window=12)
rolstd = pd.rolling_std(timeseries, window=12)
#plot rolling statistics
orig = plt.plot(timeseries, color='blue', label='Original')
mean = plt.plot(rolmean, color='red', label='Rolling Mean')
std = plt.plot(rolstd, color='black', label='Rolling Std')
plt.legend(loc='best')
plt.title('Rolling Mean and Standard Deviation')
plt.show(block=false)
#perform Dickey=Fuller test
print('Results of Dickey-Fuller Test:')
dftest = adfuller(timeseries, autolag='AIC')
dfoutput = pd.Series(dftest[0:4], index=['Test
Statistic','p-value','#Lags Used','Number of Observations Used'])
for key, value in dftest[4].items():
dfoutput['Critical Value (%s)'%key]=value
print(dfoutput)
test_stationary(ts

And see this output:
---------------------------------------------------------------------------
ImportError Traceback (most recent call last)
<ipython-input-29-2d4e66de9602> in <module>()
----> 1 from statsmodels.tsa.stattools import adfuller
2 def test_stationarity(timeseries):
3 #determining rolling statistics
4 rolmean = pd.rolling_mean(timeseries, window=12)
5 rolstd = pd.rolling_std(timeseries, window=12)

c:\python34\lib\site-packages\statsmodels\__init__.py in <module>()
6
7 from warnings import simplefilter
----> 8 from .tools.sm_exceptions import (ConvergenceWarning,
CacheWriteWarning,
9 IterationLimitWarning, InvalidTestWarning)
10

c:\python34\lib\site-packages\statsmodels\tools\__init__.py in <module>()
----> 1 from .tools import add_constant, categorical

c:\python34\lib\site-packages\statsmodels\tools\tools.py in <module>()
6 import numpy.lib.recfunctions as nprf
7 import numpy.linalg as L
----> 8 from scipy.linalg import svdvals
9 from statsmodels.distributions import (ECDF, monotone_fn_inverter,
10 StepFunction)

c:\python34\lib\site-packages\scipy\linalg\__init__.py in <module>()
172 from .linalg_version import linalg_version as __version__
173
--> 174 from .misc import *
175 from .basic import *
176 from .decomp import *

c:\python34\lib\site-packages\scipy\linalg\misc.py in <module>()
3 import numpy as np
4 from numpy.linalg import LinAlgError
----> 5 from .blas import get_blas_funcs
6 from .lapack import get_lapack_funcs
7

c:\python34\lib\site-packages\scipy\linalg\blas.py in <module>()
153 import numpy as _np
154
--> 155 from scipy.linalg import _fblas
156 try:
157 from scipy.linalg import _cblas

ImportError: DLL load failed: The specified module could not be found.

Do I read this correctly to mean that the very last import statement is
the one having the problem,

"from scipy.linalg import _fblas"

How do I troubleshoot this? I'm wondering if I have version conflict
between two modules.

Thanks,
Mike

Mark Lawrence

unread,
Feb 9, 2016, 4:33:46 AM2/9/16
to
On 09/02/2016 04:22, Mike S via Python-list wrote:
> I have Python 3.4.4 installed on Windows 7, also IPython, scipy, numpy,
> statsmodels, and a lot of other modules, and am working through this
> tutorial
> http://www.analyticsvidhya.com/blog/2016/02/time-series-forecasting-codes-python/
>

[snip bulk of code and traceback]

> 154
> --> 155 from scipy.linalg import _fblas
> 156 try:
> 157 from scipy.linalg import _cblas
>
> ImportError: DLL load failed: The specified module could not be found.
>
> Do I read this correctly to mean that the very last import statement is
> the one having the problem,
>
> "from scipy.linalg import _fblas"
>
> How do I troubleshoot this? I'm wondering if I have version conflict
> between two modules.

Alomost certainly, hopefully this link will help.

http://stackoverflow.com/questions/21350153/error-importing-scipy-linalg-on-windows-python-3-3

>
> Thanks,
> Mike

No problem :)

--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.

Mark Lawrence

Mike S

unread,
Feb 9, 2016, 6:57:45 PM2/9/16
to
On 2/9/2016 1:33 AM, Mark Lawrence wrote:
> On 09/02/2016 04:22, Mike S via Python-list wrote:
>> I have Python 3.4.4 installed on Windows 7, also IPython, scipy, numpy,
>> statsmodels, and a lot of other modules, and am working through this
>> tutorial
>> http://www.analyticsvidhya.com/blog/2016/02/time-series-forecasting-codes-python/
>
> [snip bulk of code and traceback]
>
>> 154
>> --> 155 from scipy.linalg import _fblas
>> 156 try:
>> 157 from scipy.linalg import _cblas
>> ImportError: DLL load failed: The specified module could not be found.
>> Do I read this correctly to mean that the very last import statement is
>> the one having the problem,
>> "from scipy.linalg import _fblas"
>> How do I troubleshoot this? I'm wondering if I have version conflict
>> between two modules.
>
> Alomost certainly, hopefully this link will help.
> http://stackoverflow.com/questions/21350153/error-importing-scipy-linalg-on-windows-python-3-3
>>
>> Thanks,
>> Mike
>
> No problem :)

Mark,

I uninstalled scipy, numpy and pandas, then installed this version
scipy-0.15.1-win32-superpack-python3.4
I had previously installed this version
scipy-0.16.1-win32-superpack-python3.4
That solved the conflict, you have great search skills, I tried but
didn't find a resolution.

Thanks Very Much!
Mike

0 new messages