What's Here
This document describes the [browser:trunk/hlsvdpro files that comprise this port].
Straightforward Ports
The following files have a 1:1 correlation with Fortran files of the same name: aprodw.py
, hlsvdpro.py
, lanczopw.py
, zgemmina.py
(from zgemm_ovwr.f
), zget0w.py
, zlanbprow.py
, zlansvdw.py
, zreorth.py
, and zsafescal.py
.
The files dbdsqr.py
(a [HlsvdproPortDbdsqr wrapper for the binary function]) and dlartg.py
are ports of files from BLAS/LAPACK.
New Required Files
The file util.py
contains some code used by the files above.
Unused Files
The files lanczopw_using_fortran.py
and zlansvdw_using_fortran.py
are wrappers for the Fortran versions of lanczopw()
and zlansvdw()
respectively. I used them in the process of porting while I still relied on Fortran versions of these functions.
They probably don't work anymore (the function interfaces have changed) but it wouldn't take too much to get them working again. And if nothing else, they're a useful reference on how to call Fortran from Python.
Data Files
The file first_random.txt
contains the [HlsvdproPortRandomness random numbers] generated by the first call to the Fortran function zlarnv()
in zget0w.f
. I used these numbers when trying to get my Python code to exactly match the output of the Fortran. See [browser:trunk/hlsvdpro/zget0w.py zget0w.py].
Testing Files
The files test.py
and otest.py
are siblings. The former runs the Python version of the code, the latter runs the Fortran version (a.k.a. the original version, hence the name otest
). They can be edited to use a specific default input file, to run the profiler, and to show a graph that compares HLSVD's version of the signal to the real thing.
The file stats.py
prints statistics from the profile data generated by test.py
.
Original (Fortran) Files
The "original" Fortran files are in the original
directory. This started as a copy of the Vespa version of Vespa's hlsvd
directory. As I worked I modified the Fortran to add many, many print statements and a few wrappers to make the code callable from Python. See Vespa for documentation on how to use the Makefiles.