Scipy: wrap DSYTRD

Created on 20 Aug 2017  路  4Comments  路  Source: scipy/scipy

(Moved over from https://github.com/numpy/numpy/issues/9584.)

I would like to make LAPACK's DSYTRD available to use from Python proper. Where do I have to look in the code? Where are the tests going?

enhancement scipy.linalg

Most helpful comment

LAPACK wrappers unfortunately don't have tests. Because often a Python-level function is also provided and that function is tested and hence the wrapper is also tested indirectly under the hood. But so far things are pretty consistent.

For direct addition of wrappers, here is recent #7643 as a minimal example about which files are affected. You can send a pull request based on that.

Also note that LAPACK routines comes in two or four groups (in this case ssytrd/dsytrd and chetrd/zhetrd are relevant) hence we (tend to) include all of them at one go. f2py syntax is mostly black magic so in case it doesn't go through, let us know and we can have a look at it too.

All 4 comments

LAPACK wrappers unfortunately don't have tests. Because often a Python-level function is also provided and that function is tested and hence the wrapper is also tested indirectly under the hood. But so far things are pretty consistent.

For direct addition of wrappers, here is recent #7643 as a minimal example about which files are affected. You can send a pull request based on that.

Also note that LAPACK routines comes in two or four groups (in this case ssytrd/dsytrd and chetrd/zhetrd are relevant) hence we (tend to) include all of them at one go. f2py syntax is mostly black magic so in case it doesn't go through, let us know and we can have a look at it too.

LAPACK wrappers unfortunately don't have tests.

There are tests for a number of LAPACK functions in linalg/tests/test_lapack.py. If these functions aren't tested via a Python-level function, then adding a new test there looks like the way to go.

There are tests for a number of LAPACK functions in linalg/tests/test_lapack.py. If these functions aren't tested via a Python-level function, then adding a new test there looks like the way to go.

Ouch, I've forgotten that file. After a quick glance, it looks like it needs some update though 馃槂

f2py syntax is mostly black magic

You weren't kidding. With bit of work and luck, I've managed to make myself familiar with it and coughed up https://github.com/scipy/scipy/pull/7780. I'll be glad to take comments.

Was this page helpful?
0 / 5 - 0 ratings