A package that is able to run ALAMO without the use of its GUI
Project description
alamopy
This is an interface for using ALAMO through a Python pip package.
Preparation :
for MacOS users:
Download the ALAMO application from minlp.com, and unzip the package.
for Windows users:
Download the ALAMO application from minlp.com, and install with the provided installer.
Data to run ALAMO:
Add the directory of the folder you have installed the pip package with your Python file to your PATH variable.
Get your ALAMO license from minlp.com and place it inside the same folder as the Python file.
Before running ALAMO, you should decide if you will provide your own data. If so, make sure your data are all in numpy arrays. Otherwise, select the appropriate simulator to run ALAMO.
pip install alamopy
python
import numpy as np
Example
Test 1 to see if we can generate model for z = x**2 Most notably tests if the given example 1 works from ALAMO UI.
from alamopy import almain as alamo
import numpy as np
xdata = np.random.rand(11, 1)
xdata[:, 0] = [-5,-4,-3,-2,-1,0,1,2,3,4,5]
zdata = xdata[:, 0]**2
opts = alamo.doalamo(xdata, zdata, linfcns = 1, logfcns = 1, sinfcns = 1, cosfns = 1, constant = 1, expfcns = 1, monomialpower = [2,3], keep_alm_file=True, keep_lst_file=True)
Outputs from ALAMO
You would get the result dictionary with a best-fitted function and other variables when calling ALAMO using this python interface.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file alamopy-0.2.2.tar.gz
.
File metadata
- Download URL: alamopy-0.2.2.tar.gz
- Upload date:
- Size: 16.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 19a797db8d80e9759a39544890633354a658e348facb636e31ae6113cdd0e29a |
|
MD5 | 4ed4e6020e9d0a5ffa1cd59959a26efe |
|
BLAKE2b-256 | 6270dcf2f293534a7f6049509c7048eb18bfb51fc04b54a6f907e0ff800c3b70 |
File details
Details for the file alamopy-0.2.2-py3-none-any.whl
.
File metadata
- Download URL: alamopy-0.2.2-py3-none-any.whl
- Upload date:
- Size: 21.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.21.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d0c8c31e9623732fa263e88dd30d904fcaaf04b115960f7202be9f8f65159449 |
|
MD5 | 882fe8fd5fd08db767fc44b095849a8f |
|
BLAKE2b-256 | e9f1a3db9c82086b84db3804bbfc8942a95712b93b89ea07d7fd40c7af930929 |