Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build opensim-moco 451 #37

Merged
merged 46 commits into from
Oct 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
1d2eb0e
Add files for opensim-moco package
aymanhab Jun 12, 2023
df4b99b
Fix unix build script
aymanhab Jun 12, 2023
27d5723
Add moco builds to ci on windows, linux
aymanhab Jun 12, 2023
e8b21d1
builds based on main branch
aymanhab Jun 12, 2023
747a2fe
Update continuous_integration.yml
aymanhab Jun 14, 2023
4d5418f
Switch to branch 441
aymanhab Jul 13, 2023
1db2447
fix branch name and build number
aymanhab Jul 14, 2023
b7efa1e
fix branch name and build number for 4.4.1
aymanhab Jul 14, 2023
2a68a02
Add python 3.9, np 120 variant
aymanhab Jul 18, 2023
a71071d
Run test after build and add in python 3.9, numpy 1.20 pair
aymanhab Jul 20, 2023
d3accbd
Update continuous_integration.yml
aymanhab Jul 20, 2023
d520cef
try building latest main branch and copy simbody-visualizer on *nix
aymanhab Nov 2, 2023
03f7a09
update ci to match versions in other config files
aymanhab Nov 2, 2023
905f099
Update continuous_integration.yml
aymanhab Nov 2, 2023
ed01f79
Update continuous_integration.yml
aymanhab Nov 2, 2023
db90607
Revert to swig 4.0.2
aymanhab Nov 2, 2023
d1e62c7
Merge branch 'build_pkgs_latest' of https://github.com/opensim-org/co…
aymanhab Nov 2, 2023
5c8a3a7
Use version 4.5
aymanhab Nov 21, 2023
ab76d7b
use opensim_45 branch
aymanhab Nov 29, 2023
2cdee1d
Update continuous_integration.yml
aymanhab Dec 1, 2023
a85691a
Update build.sh
aymanhab Dec 2, 2023
58da129
Update build.sh
aymanhab Dec 2, 2023
52b45c1
Update continuous_integration.yml
aymanhab Dec 2, 2023
63152ce
build branch upgrade_ipopt to test and limit to python 3.10,11
aymanhab May 16, 2024
fddd0aa
Update continuous_integration.yml
aymanhab Jun 3, 2024
ceccd5d
Update conda_build_config.yaml
aymanhab Jun 3, 2024
6fcb768
Update meta.yaml
aymanhab Jun 3, 2024
adad291
Update conda_build_config.yaml
aymanhab Jun 3, 2024
cd83959
Update meta.yaml
aymanhab Jun 3, 2024
935bce1
Update continuous_integration.yml
aymanhab Jun 3, 2024
e3bb83e
Update continuous_integration.yml
aymanhab Jun 3, 2024
38b83cc
Update continuous_integration.yml
aymanhab Jun 3, 2024
31d6d28
Fix formatting/indentation
aymanhab Jun 3, 2024
88afe5a
Build opensim-moco and opensim version 4.5.1 based on main branch of …
aymanhab Jun 23, 2024
51c44bf
Update continuous_integration.yml
aymanhab Jun 24, 2024
6e34ede
Update conda_build_config.yaml
aymanhab Jun 24, 2024
1b1d650
Update build.sh
aymanhab Jun 24, 2024
e8f0a5f
Update conda_build_config.yaml
aymanhab Jun 24, 2024
fce422a
Update meta.yaml
aymanhab Jun 24, 2024
462ec29
Update conda_build_config.yaml
aymanhab Jun 25, 2024
8eea115
Add blank lines to try to fix parsing
aymanhab Jun 25, 2024
d8222a1
Update continuous_integration.yml
aymanhab Jun 25, 2024
affab2f
Update build.sh
aymanhab Jun 25, 2024
e81b0c9
Update meta.yaml
aymanhab Jun 25, 2024
92d1b08
Update continuous_integration.yml
aymanhab Jun 25, 2024
06bb372
Update continuous_integration.yml
aymanhab Jun 25, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
207 changes: 27 additions & 180 deletions .github/workflows/continuous_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,95 +2,28 @@ name: continuous-integration

# syntax https://help.github.com/en/articles/workflow-syntax-for-github-actions
on:
# Run at 2am every night.
schedule:
- cron: '0 2 * * *'
pull_request:
branches:
- '*'
push:
branches:
- master
jobs:
windows38:
runs-on: windows-latest

steps:
- uses: actions/checkout@v1

- name: Install Python packages
uses: actions/setup-python@v2
with:
python-version: '3.8'

- name: Install numpy
#Need numpy to use SWIG numpy typemaps.
run: python -m pip install numpy==1.20

- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
miniconda-version: "latest"
- name: Install conda-build
run: conda install conda-build

- name: Conda build
run: |
chdir $env:GITHUB_WORKSPACE
conda build .

- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: win64-opensim-4.4-py38np120.tar.bz2
path: C:/Miniconda3/envs/test/conda-bld/win-64/opensim-4.4-py38np120.tar.bz2
windows39:
runs-on: windows-latest

steps:
- uses: actions/checkout@v1

- name: Install Python packages
uses: actions/setup-python@v2
with:
python-version: '3.9'

- name: Install numpy
#Need numpy to use SWIG numpy typemaps.
run: python -m pip install numpy==1.20

- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
miniconda-version: "latest"
- name: Install conda-build
run: conda install conda-build

- name: Conda build
run: |
chdir $env:GITHUB_WORKSPACE
conda build .

- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: win64-opensim-4.4-py39np120.tar.bz2
path: C:/Miniconda3/envs/test/conda-bld/win-64/opensim-4.4-py39np120.tar.bz2

jobs:
windows310:
runs-on: windows-latest

steps:
- uses: actions/checkout@v1

- name: Install Python packages
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.10'

- name: Install numpy
#Need numpy to use SWIG numpy typemaps.
run: python -m pip install numpy==1.21.4
run: python -m pip install numpy==1.25

- uses: conda-incubator/setup-miniconda@v2
with:
Expand All @@ -101,29 +34,29 @@ jobs:

- name: Conda build
run: |
chdir $env:GITHUB_WORKSPACE
chdir $env:GITHUB_WORKSPACE/opensim
conda build .

- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: win64-opensim-4.4-py310np121.tar.bz2
path: C:/Miniconda3/envs/test/conda-bld/win-64/opensim-4.4-py310np121.tar.bz2
name: win64-opensim-4.5.1-py310np121.tar.bz2
path: C:/Miniconda3/envs/test/conda-bld/win-64/opensim-4.5.1-py310np125.tar.bz2

windows311:
windows310-moco:
runs-on: windows-latest

steps:
- uses: actions/checkout@v1

- name: Install Python packages
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.11'
python-version: '3.10'

- name: Install numpy
#Need numpy to use SWIG numpy typemaps.
run: python -m pip install numpy==1.23
run: python -m pip install numpy==1.25

- uses: conda-incubator/setup-miniconda@v2
with:
Expand All @@ -134,101 +67,15 @@ jobs:

- name: Conda build
run: |
chdir $env:GITHUB_WORKSPACE
chdir $env:GITHUB_WORKSPACE/opensim-moco
conda build .

- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: win64-opensim-4.4-py311np123.tar.bz2
path: C:/Miniconda3/envs/test/conda-bld/win-64/opensim-4.4-py311np123.tar.bz2

ubuntu38:
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: 3.8
channels: conda-forge,defaults
miniconda-version: "latest"
name: win64-opensim-moco-4.5.1-py310np125.tar.bz2
path: C:/Miniconda3/envs/test/conda-bld/win-64/opensim-moco-4.5.1-py310np125.tar.bz2

- name: Install Python packages
uses: actions/setup-python@v4
with:
python-version: '3.8'

- name: Install packages
run: sudo apt-get update && sudo apt-get install --yes build-essential libtool autoconf pkg-config gfortran libopenblas-dev liblapack-dev freeglut3-dev libxi-dev libxmu-dev doxygen python3.8 python3-dev python3-numpy python3-setuptools

- name: Install SWIG
run: |
mkdir ~/swig-source && cd ~/swig-source
wget https://github.com/swig/swig/archive/refs/tags/rel-4.0.2.tar.gz
tar xzf rel-4.0.2.tar.gz && cd swig-rel-4.0.2
sh autogen.sh && ./configure --prefix=$HOME/swig --disable-ccache
make && make -j4 install

- name: Install conda-build
run: conda install conda-build

- name: Conda build
run: |
cd $GITHUB_WORKSPACE/opensim
conda build .

- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: linux64-opensim-4.4-py38np120.tar.bz2
path: /usr/share/miniconda3/conda-bld/linux-64/opensim-4.4-py38np120.tar.bz2
ubuntu39:
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: 3.9
channels: conda-forge,defaults
miniconda-version: "latest"

- name: Install Python packages
uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Install numpy
#Need numpy to use SWIG numpy typemaps.
run: python3 -m pip install numpy==1.20.2

- name: Install packages
run: sudo apt-get update && sudo apt-get install --yes build-essential libtool autoconf pkg-config gfortran libopenblas-dev liblapack-dev freeglut3-dev libxi-dev libxmu-dev doxygen python3 python3-dev python3-numpy python3-setuptools

- name: Install SWIG
run: |
mkdir ~/swig-source && cd ~/swig-source
wget https://github.com/swig/swig/archive/refs/tags/rel-4.0.2.tar.gz
tar xzf rel-4.0.2.tar.gz && cd swig-rel-4.0.2
sh autogen.sh && ./configure --prefix=$HOME/swig --disable-ccache
make && make -j4 install

- name: Install conda-build
run: conda install conda-build

- name: Conda build
run: |
cd $GITHUB_WORKSPACE/opensim
conda build .

- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: linux64-opensim-4.4-py39np120.tar.bz2
path: /usr/share/miniconda3/conda-bld/linux-64/opensim-4.4-py39np120.tar.bz2
ubuntu310:
runs-on: ubuntu-20.04

Expand All @@ -248,16 +95,16 @@ jobs:

- name: Install numpy
#Need numpy to use SWIG numpy typemaps.
run: python3 -m pip install numpy==1.21
run: python3 -m pip install numpy==1.25

- name: Install packages
run: sudo apt-get update && sudo apt-get install --yes build-essential libtool autoconf pkg-config gfortran libopenblas-dev liblapack-dev freeglut3-dev libxi-dev libxmu-dev doxygen python3 python3-dev python3-numpy python3-setuptools

- name: Install SWIG
run: |
mkdir ~/swig-source && cd ~/swig-source
wget https://github.com/swig/swig/archive/refs/tags/rel-4.0.2.tar.gz
tar xzf rel-4.0.2.tar.gz && cd swig-rel-4.0.2
wget https://github.com/swig/swig/archive/refs/tags/v4.1.1.tar.gz
tar xzf v4.1.1.tar.gz && cd swig-4.1.1
sh autogen.sh && ./configure --prefix=$HOME/swig --disable-ccache
make && make -j4 install

Expand All @@ -272,38 +119,38 @@ jobs:
- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: linux64-opensim-4.4-py310np121.tar.bz2
path: /usr/share/miniconda3/conda-bld/linux-64/opensim-4.4-py310np121.tar.bz2
name: linux64-opensim-4.5-py310np121.tar.bz2
path: /usr/share/miniconda3/conda-bld/linux-64/opensim-4.5.1-py310np125.tar.bz2

ubuntu311:
ubuntu310-moco:
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: '3.11'
python-version: '3.10'
channels: conda-forge,defaults
miniconda-version: "latest"

- name: Install Python packages
uses: actions/setup-python@v4
with:
python-version: '3.11'
python-version: '3.10'

- name: Install numpy
#Need numpy to use SWIG numpy typemaps.
run: python3 -m pip install numpy==1.23
run: python3 -m pip install numpy==1.25

- name: Install packages
run: sudo apt-get update && sudo apt-get install --yes build-essential libtool autoconf pkg-config gfortran libopenblas-dev liblapack-dev freeglut3-dev libxi-dev libxmu-dev doxygen python3 python3-dev python3-numpy python3-setuptools

- name: Install SWIG
run: |
mkdir ~/swig-source && cd ~/swig-source
wget https://github.com/swig/swig/archive/refs/tags/rel-4.0.2.tar.gz
tar xzf rel-4.0.2.tar.gz && cd swig-rel-4.0.2
wget https://github.com/swig/swig/archive/refs/tags/v4.1.1.tar.gz
tar xzf v4.1.1.tar.gz && cd swig-4.1.1
sh autogen.sh && ./configure --prefix=$HOME/swig --disable-ccache
make && make -j4 install

Expand All @@ -312,14 +159,14 @@ jobs:

- name: Conda build
run: |
cd $GITHUB_WORKSPACE/opensim
cd $GITHUB_WORKSPACE/opensim-moco
conda build .

- name: upload artifact
uses: actions/upload-artifact@v2
with:
name: linux64-opensim-4.4-py311np123.tar.bz2
path: /usr/share/miniconda3/conda-bld/linux-64/opensim-4.4-py311np123.tar.bz2
name: linux64-opensim-moco-4.5.1-py310np125.tar.bz2
path: /usr/share/miniconda3/conda-bld/linux-64/opensim-moco-4.5.1-py310np125.tar.bz2

style:
name: Style
Expand Down
41 changes: 41 additions & 0 deletions opensim-moco/bld.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
mkdir opensim_dependencies_build
cd .\opensim_dependencies_build
cmake ..\dependencies^
-G"Visual Studio 17 2022"^
-DCMAKE_INSTALL_PREFIX="%LIBRARY_PREFIX%"^
-DSUPERBUILD_ezc3d=ON^
-DOPENSIM_WITH_TROPTER=ON^
-DOPENSIM_WITH_CASADI=ON

cmake --build . --config Release -- /maxcpucount:8
cd ..
mkdir opensim_build
cd .\opensim_build
cmake ..\^
-G"Visual Studio 17 2022"^
-DCMAKE_INSTALL_PREFIX="%LIBRARY_PREFIX%"^
-DOPENSIM_DEPENDENCIES_DIR="%LIBRARY_PREFIX%"^
-DCMAKE_INSTALL_INCLUDEDIR="%LIBRARY_PREFIX%/include"^
-DCMAKE_INSTALL_LIBDIR="%LIBRARY_PREFIX%/lib"^
-DCMAKE_INSTALL_DOCDIR="%LIBRARY_PREFIX%/doc"^
-DCMAKE_INSTALL_SYSCONFDIR="%LIBRARY_PREFIX%/Library"^
-DOPENSIM_INSTALL_PYTHONDIR="%LIBRARY_PREFIX%/Lib/site-packages"^
-DOPENSIM_INSTALL_SIMBODYDIR="%LIBRARY_PREFIX%/Library/Simbody"^
-DOPENSIM_INSTALL_SPDLOGDIR="%LIBRARY_PREFIX%/Library/spdlog"^
-DOPENSIM_INSTALL_CASADIDIR="%LIBRARY_PREFIX%/Library"^
-DBUILD_PYTHON_WRAPPING=ON^
-DOPENSIM_C3D_PARSER=ezc3d^
-DOPENSIM_PYTHON_STANDALONE=ON^
-DOPENSIM_WITH_CASADI=ON^
-DOPENSIM_WITH_TROPTER=ON^
-DBUILD_TESTING=OFF^
-DBUILD_API_EXAMPLES=OFF^
-DOPENSIM_BUILD_INDIVIDUAL_APPS=ON^
-DOPENSIM_PYTHON_CONDA=ON
cmake --build . --target install --config Release -- /maxcpucount:8

Rem move Library\sdk\Python Lib
move %LIBRARY_PREFIX%\sdk\Python %LIBRARY_PREFIX%\..\Lib
cd %LIBRARY_PREFIX%\..\Lib
python setup.py install

Loading
Loading