Fast Function Extraction
Python Shell
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
ffx
tests
.gitignore updated gitignore file. Mar 15, 2012
LICENSE
Readme.md Mention Py3k Jul 28, 2016
push_to_pypi.sh
setup.py

Readme.md

FFX: Fast Function Extraction

FFX is a technique for symbolic regression. It is:

  • Fast - runtime 5-60 seconds, depending on problem size (1GHz cpu)
  • Scalable - 1000 input variables, no problem!
  • Deterministic - no need to "hope and pray".

Installation

To install from PyPI, simply run:

pip install ffx

Usage

FFX can either be run in stand-alone mode, or within your existing Python code. It installs both a command-line utility runffx and the Python module ffx.

Standalone

runffx test train_X.csv train_y.csv test_X.csv test_y.csv

Use runffx help for more information on using the command-line utility.

Python Module

The following snippet is a simple example of how to use FFX. Note that all arguments are expected to be of type numpy.ndarray or pandas.DataFrame.

import numpy as np
import ffx

train_X = np.array( [ (1.5,2,3), (4,5,6) ] ).T
train_y = np.array( [1,2,3])

test_X = np.array( [ (5.241,1.23, 3.125), (1.1,0.124,0.391) ] ).T
test_y = np.array( [3.03,0.9113,1.823])

models = ffx.run(train_X, train_y, test_X, test_y, ["predictor_a", "predictor_b"])
for model in models:
    yhat = model.simulate(test_X)
    print model

Presently, the FFX Python module only exposes a single API method, ffx.run().

Dependencies

  • python (tested on 2.5, 2.6, 2.7, and 3.5)
  • numpy (1.6.0+)
  • scipy (0.9.0+)
  • scikit-learn (0.9+)
  • pandas (optional, enables support for labeled pandas.DataFrame datasets)

Technical details

References

  1. McConaghy, FFX: Fast, Scalable, Deterministic Symbolic Regression Technology, Genetic Programming Theory and Practice IX, Edited by R. Riolo, E. Vladislavleva, and J. Moore, Springer, 2011.
  2. McConaghy, High-Dimensional Statistical Modeling and Analysis of Custom Integrated Circuits, Proc. Custom Integrated Circuits Conference, Sept. 2011