Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with Rind not being loaded #16

Closed
eelcovv opened this issue Jan 12, 2016 · 2 comments
Closed

Issues with Rind not being loaded #16

eelcovv opened this issue Jan 12, 2016 · 2 comments

Comments

@eelcovv
Copy link

eelcovv commented Jan 12, 2016

Hello,
I have installed pywafo and tried to run the tutorials but I am running into some issues. From chapter 1 I have here given the smallest example to raise the error I have installed the pywafo project from this repository, but also tried the anaconda version which gives the same error

The example is:

import wafo.spectrum.models as wsm
import wafo.objects as wo

try:
    from win32api import LoadResource
except ImportError:
    pass

S = wsm.Torsethaugen(Hm0=6, Tp=8)
S1 = S.tospecdata()

dtyex = S1.to_t_pdf(pdef='Tt', paramt=(0, 10, 51), nit=3)

Running this code raises the issue

 File "C:/Data/Eelco/Python Scripts/PyCharm/pywafo_examples/tutorial_scripts/bug_example.py", line 14, in <module>
    dtyex = S1.to_t_pdf(pdef='Tt', paramt=(0, 10, 51), nit=3)
  File "C:\Apps\Anaconda\Anaconda2\lib\site-packages\wafo-0.1.2-py2.7.egg\wafo\spectrum\core.py", line 1369, in to_t_pdf
    rind = Rind(**opts)
TypeError: 'NoneType' object is not callable

It appears that Rind is loaded in wafo.gauss, however, this is not done correctly and therefore remains None

Therefore, as a work around I try to force to load wafo.gauss.Rind again before I call the to_t_pdf as

 from wafo.gaussian import Rind 

Now Rind seems to be loaded, but I get the following error

Traceback (most recent call last):
  File "C:/Data/Eelco/Python Scripts/PyCharm/pywafo_examples/tutorial_scripts/bug_example.py", line 14, in <module>
    from wafo.gaussian import Rind
  File "C:\Apps\Anaconda\Anaconda2\lib\site-packages\wafo-0.1.2-py2.7.egg\wafo\gaussian.py", line 7, in <module>
    from wafo import mvn
ImportError: DLL load failed: %1 is not a valid Win32 application.

I am not sure if this error is related to the first problem. Anyhow. Any idea how I could fix this?

Many thanks

Regards
Eelco

@davidovitch
Copy link
Member

Thanks for reporting this. I hope this problem will be fixed when the pipinstall branch is merged with master. It is further discussed in issue #14.

@davidovitch
Copy link
Member

There are still issues when building on Windows. Closing here but the discussion continues in #29.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants