Usage

Documentation

aifeynman.launch(pathdir, filename[, BF_try_time=60][, BF_ops_file_type='14ops.txt'][, polyfit_deg=4][, NN_epochs=4000][, vars_name=[]][, test_percentage=0])

Runs AI Feynman. Saves the solutions to results/ directory to the file results/solution_{filename}. Parameters in [square brackets] are optional.

Parameters
  • pathdir (str) – path to the directory containing the data file

  • filename (str) – the name of the file containing the data

  • BF_try_time (float) – time limit in seconds for each brute force call (default is 60 seconds)

  • BF_ops_file_type (str) – file containing the symbols to be used in the brute force code (default is “14ops.txt”)

  • polyfit_deg (int) – maximum degree of the polynomial tried by the polynomial fit routine (default is 4)

  • NN_epochs (int) – number of epochs for the training (default is 4000)

  • vars_name ([str]) – name of the variables appearing in the equation (including the name ofthe output variable). This should be passed as a list of strings, with the name of the variables appearing in the same order as in the input data

  • test_percentage (float) – percentage of the input data to be kept aside and used as a test set

The data file to be analyzed should be a text file with each column containing the numerical values of each (dependent and independent) variable. The solution file will be saved in the directory called “results” under the name solution_{filename}. The solution file will contain several rows (corresponding to each point on the Pareto frontier), each row showing:

  • the mean logarithm in based 2 of the error of the discovered equation applied to the input data (this can be though of as the average error in bits)

  • the cummulative logarithm in based 2 of the error of the discovered equation applied to the input data (this can be though of as the cummulative error in bits)

  • the complexity of the discovered equation (in bits)

  • the error of the discovered equation applied to the input data

  • the symbolic expression of the discovered equation

If test_percentage is different than zero, one more number is added in the beginning of each row, showing the error of the discovered equation on the test set.

For more information on input and output formats, see Input format and Output format