|
|
# Pre-requisite
|
|
|
|
|
|
In order to run the Optimal Control Module of SEMpy, you will have to download manually the following libraries: IPOPT, BLAS, Lapack, ASL, Metis, Mumps, HSL, IPyOPT, and Cppad_py.
|
|
|
|
|
|
Here are the following links:
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
|
|
|
|
|
|
|
|
|
# 1. Installing SEMpy Optimal Control Module
|
|
|
|
|
|
Please enter the following command lines:
|
|
|
|
|
|
* In the Anaconda command prompt if you are a Windows Users
|
|
|
|
|
|
* In you system bash if you are a Linux/Mac user
|
|
|
|
|
|
## 1.1 Create a folder containing SEMpy's recipe
|
|
|
|
|
|
We recommend you to have a fixed working directory:
|
|
|
```bash
|
|
|
mkdir sempy
|
|
|
cd sempy
|
|
|
```
|
|
|
Then get SEMpy's recipe
|
|
|
```bash
|
|
|
git clone https://gitlab.isae-supaero.fr/sempy/sempy-recipe.git
|
|
|
cd sempy-recipe
|
|
|
```
|
|
|
|
|
|
## 1.2 Build and install SEMpy package
|
|
|
|
|
|
Now that you entered the sempy-recipe folder, run:
|
|
|
```bash
|
|
|
conda build . -c conda-forge
|
|
|
```
|
|
|
|
|
|
Now that the package is built, you can install the Optimal Control Module on your machine.
|
|
|
|
|
|
Note: We recommand to create a new environment to install SEMpy, to avoid conflicts with already installed packages
|
|
|
|
|
|
Then install the Optimal Control Module of SEMpy :
|
|
|
|
|
|
```bash
|
|
|
conda install --use-local sempy_optimal_control
|
|
|
```
|
|
|
|
|
|
## 1.3 Testing SEMpy
|
|
|
|
|
|
### Linux - Debian
|
|
|
|
|
|
From now, get back to your home directory, and then go to Anaconda3's packages location
|
|
|
```bash
|
|
|
cd
|
|
|
cd anaconda3/pkgs/
|
|
|
```
|
|
|
Note : You will have to test both the Core Module and the Optimal Control Module.
|
|
|
|
|
|
Look for the complete names of your packages (sempy_core and sempy_optimal_control) with:
|
|
|
|
|
|
```bash
|
|
|
ls
|
|
|
```
|
|
|
Then run :
|
|
|
|
|
|
```bash
|
|
|
cd <complete-package-name>/lib/python3.8/site-packages/sempy/<core-or-optimal_control>/
|
|
|
```
|
|
|
|
|
|
And then run the unittests
|
|
|
```bash
|
|
|
python -m unittest
|
|
|
```
|
|
|
|
|
|
### Windows
|
|
|
|
|
|
From now, get back to your home directory, and then go the SEMpy's location
|
|
|
```bash
|
|
|
cd \
|
|
|
cd Users\<your-username>\Anaconda3\pkgs\
|
|
|
```
|
|
|
|
|
|
Note : You will have to test both the Core Module and the Optimal Control Module.
|
|
|
|
|
|
Look for the complete names of your packages (sempy_core and sempy_optimal_control) with:
|
|
|
|
|
|
```bash
|
|
|
dir
|
|
|
```
|
|
|
|
|
|
Then run:
|
|
|
|
|
|
```bash
|
|
|
cd <complete-package-name>\lib\python3.8\site-packages\sempy\<core-or-optimal_control>\
|
|
|
```
|
|
|
|
|
|
And then run the unittests
|
|
|
```bash
|
|
|
python -m unittest
|
|
|
```
|
|
|
|
|
|
### macOS
|
|
|
|
|
|
From now, get back to your home directory, and then go the SEMpy's location
|
|
|
```bash
|
|
|
cd
|
|
|
cd opt/anaconda3/pkgs/
|
|
|
```
|
|
|
Note : You will have to test both the Core Module and the Optimal Control Module.
|
|
|
|
|
|
Look for the complete names of your packages (sempy_core and sempy_optimal_control) with:
|
|
|
|
|
|
```bash
|
|
|
ls
|
|
|
```
|
|
|
|
|
|
Then run :
|
|
|
|
|
|
```bash
|
|
|
cd <complete-package-name>/lib/python3.8/site-packages/sempy/<core-or-optimal_control>/
|
|
|
```
|
|
|
|
|
|
And then run the unittests
|
|
|
```bash
|
|
|
python -m unittest
|
|
|
```
|
|
|
|
|
|
If all tests succeeded, SEMpy lib Core and Optimal Control is now ready to use! |
|
|
\ No newline at end of file |