python

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

python

Max Giolitti
Hi All,
I  installed 0.3.13 of QuantLib and compiled it in fedora 5, I can run all the tests fine. I am trying to get the python extension working, and it semi works, in the sense that QuantLibTestSuite in the test subdirectory runs succesfully, but when I try to run swap I get the following:
>>> import swap
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
  File "swap.py", line 95, in ?
    floatingLegAdjustment)
  File "/usr/lib/python2.4/site-packages/QuantLib/QuantLib.py", line 5238, in __init__
    this = _QuantLib.new_SwapRateHelper(*args)
NotImplementedError: No matching function for overloaded 'new_SwapRateHelper'
>
I am not sure in the compilation worked correctly. Is there any special directory that I need to put the swig directory in relative to the quantlib?
Thx for your help. I got this kind of error when I was mixing the 11 version with the 13 ersion since the rpms are v11, so i want to make sure i am not making the same mistake again
Max
Reply | Threaded
Open this post in threaded view
|

Re: python

Luigi Ballabio

On Sep 18, 2006, at 7:40 AM, Max Giolitti wrote:

> I  installed 0.3.13 of QuantLib and compiled it in fedora 5, I can run
> all the tests fine. I am trying to get the python extension working,
> and it semi works, in the sense that QuantLibTestSuite in the test
> subdirectory runs succesfully, but when I try to run swap I get the
> following:
> >>> import swap
> Traceback (most recent call last):
>   File "<stdin>", line 1, in ?
>   File "swap.py", line 95, in ?
>     floatingLegAdjustment)
>   File "/usr/lib/python2.4/site-packages/QuantLib/QuantLib.py", line
> 5238, in __init__
>     this = _QuantLib.new_SwapRateHelper(*args)
> NotImplementedError: No matching function for overloaded
> 'new_SwapRateHelper'
> >
> I am not sure in the compilation worked correctly. Is there any
> special directory that I need to put the swig directory in relative to
> the quantlib?
> Thx for your help. I got this kind of error when I was mixing the 11
> version with the 13 ersion since the rpms are v11, so i want to make
> sure i am not making the same mistake again

Python might still be picking up the 0.3.11 version instead of the one
you compiled. Did you install the compiled Python module? (You have to
execute either "make -C Python install" from the QuantLib-SWIG
directory or "python setup.py install" from its Python subdirectory.)

Luigi