[obspy-users] OBSPY and PyInstaller

Ra Cleave ra at rippletech.co.nz
Thu Feb 14 13:42:17 CET 2013


Hello again,

I copied the "obspy" directory from C:\Python27\Lib\site-packages\ to my 
"dist" directory, and this solved the import problem...to an extent. The 
runtime now finds functions such as readSEGY, which I have imported as:

from obspy.segy.core import readSEGY

however functions such as detrend, which are called as member functions 
of a Stream variable, cause the following error:

   File "C:\Python27\Lib\site-packages\obspy\core\stream.py", line 2105, 
in detrend
     tr.detrend(type=type)
   File "C:\Python27\Lib\site-packages\obspy\core\trace.py", line 1619, 
in detrend
     func = _getFunctionFromEntryPoint('detrend', type)
   File "C:\Python27\Lib\site-packages\obspy\core\util\base.py", line 
343, in _getFunctionFromEntryPoint
     raise ImportError(msg % (group.capitalize()))
ImportError: Your current ObsPy installation does not support any 
Detrend functions. Please make sure SciPy is installed properly.

I suspect that this error is similar to my original one, i.e. the 
required obspy modules have not been converted to .pyd files in the 
correct way.

Thanks,
Ra



On 14/02/2013 11:31 a.m., Ra Cleave wrote:
>
> Hi,
>
> I'm struggling to get obspy working with PyInstaller. If anyone has 
> had success with this please send tips/links/etc.
>
> I have tried with PyInstaller and py2exe, with similar results. With 
> PyInstaller, and obspy installed from the sourceforge executable, I 
> get the following runtime error:
>
> ImportError: Could not load shared library for obspy.segy.
>
>  [Error 126] The specified module could not be found
>
>
> This error is generated by osbpy.segy.util(). The fact that the 
> exectuable knows about this function is a good start, and when I use 
> the PyInstaller Archive Viewer I can see that obspy.segy.core, amongst 
> other obspy modules, is included in the .pyz archive. The problem 
> seems to be that the obs.*.pyd files are not included in the "dist" 
> directory.
>
> Any help is much appreciated,
> Ra
>
> _______________________________________________
> obspy-users mailing list
> obspy-users at lists.sevor.de
> http://lists.obspy.org/cgi-bin/mailman/listinfo/obspy-users
>





More information about the obspy-users mailing list