• Home
  • Publications
  • Research
  • Teaching
  • Misc.
    • PyLeap
  • Music
    • Adrien Gomar
    • How To Eat Like A Pig And Not Get Fat


PyLeap



Python Almost Periodic Sampling Algorithms

A python library for the pre-processing of Harmonic Balance computations



View the Project on GitHub
gomar/PyLeap


Download
ZIP File
Download
TAR Ball
Fork on
GitHub


A python library for the pre-processing of Harmonic Balance computations



The sampling being a key point for the stability of the method, different algorithms are implemented to automatically choose non-uniform time-sampling that minimize the condition number of the almost-periodic DFT/IDFT matrix. Two types of class are available in the package:
  • HbComputation: Object that represents an HB computation. The almost-periodic DFT/IDFT matrices can be computed as well as their condition number,
  • HbAlgo: Objects that represent algorithms to automatically choose the best timelevels that minimize the condition number of the DFT/IDFT matrix.

Requierements


PyLeap is based on Numpy and Scipy which are python packages for scientific computing. PyLeap has been tested with python 2.4+.

How to use PyLeap?


The library comes with two scripts that uses the module:
  • bench_algo: comparison of the implemented/proposed algorithms,
  • timelevels_distribution: compare the distribution of the time levels.
They are located in the folder applications of the package. See README of each sub folder for any further information. If the scripts are executed in-place, no installation is needed. In fact, on script, the folder PyLeap is appened to the PYTHONPATH:

import sys
# dirty way to add module to pythonpath
sys.path.append('../..')

How to install PyLeap?


To definitely install PyLeap, you must add the downloaded folder PyLeap to your PYTHONPATH environment variable so that the folder pyleap is seen by python:
  • in bash:
  • export PYTHONPATH=$PYTHONPATH:'PATH/TO/PyLeap'
    
  • in csh:
  • setenv PYTHONPATH $PYTHONPATH':PATH/TO/PyLeap'
    
  • Or simply go into the PyLeap top folder and open a python shell:
  • from pyleap import *
    




Back to top