This is the mail archive of the gsl-discuss@sources.redhat.com mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ANN: PyrexGsl 0.01


>> PyrexGsl is a Pyrex interface to GSL.
> How does this compare to pygsl?

pygsl is Python library, which means that its functions
depend on Python objects, which are transformed
back and forth in the C-types used by GSL.


PyrexGsl is a Pyrex library, with C-type functions,
depending only on the C-types used by GSL.
A piece of Pyrex code with only C-type functions
is transformed by the Pyrex compiler in the
corresponding C code, which is essentially the same.

To export the result to Python, one uses
a Python-type function, which returns a Python object.
The Pyrex compiler creates the appropriate
C-Python interface for the Python-type function.

Each approach has advantages and disadvantages.

Advantaged of pygsl:
-no compilation phase
-automatic memory management
-exceptions
-interface with Numeric provided

Disadvantages of pygsl:
-It is significantly slower than GSL.

Advantage of PyrexGsl:
-It is almost as fast as GSL in long computations
 (lot of GSL function calls, Monte Carlo)

Disadvantages of PyrexGsl:
- it is necessary to compile
- memory management necessary (as in GSL)
- no exceptions.
- no interface with Numeric provided.

Greetings
  Mario





Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]