Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
7 changes: 4 additions & 3 deletions .github/workflows/build-mac-arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
MACOSX_DEPLOYMENT_TARGET: "12.0"
SW_CLOUD_LOGIN: ${{ secrets.CLOUD_LOGIN }}
CACHE_HOST: ${{ secrets.SSH_HOST }}
GA_MEASUREMENT_ID: ${{ secrets.GA_MEASUREMENT_ID }}
Expand Down Expand Up @@ -55,7 +56,7 @@ jobs:
uses: actions/cache/restore@v3
with:
path: /Users/runner/install
key: ${{ runner.os }}-arm64-deps-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}
key: ${{ runner.os }}-arm64-deps-osx${{ env.MACOSX_DEPLOYMENT_TARGET }}-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}

- name: Build Dependencies
if: steps.cache-deps-restore.outputs.cache-hit != 'true'
Expand All @@ -67,11 +68,11 @@ jobs:
uses: actions/cache/save@v3
with:
path: /Users/runner/install
key: ${{ runner.os }}-arm64-deps-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}
key: ${{ runner.os }}-arm64-deps-osx${{ env.MACOSX_DEPLOYMENT_TARGET }}-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}

- name: cmake
shell: bash -l {0}
run: conda activate shapeworks && mkdir build && cd build && cmake -DCMAKE_LIBTOOL=/usr/bin/libtool -DCMAKE_CXX_FLAGS="-g -Wno-enum-constexpr-conversion" -DCMAKE_PREFIX_PATH=$HOME/install -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DPython3_ROOT_DIR:FILEPATH=${CONDA_PREFIX} -DUSE_OPENMP=OFF -DBuild_Studio=ON -DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/shapeworks-install -DBUILD_DOCUMENTATION=ON -DGA_MEASUREMENT_ID=$GA_MEASUREMENT_ID -DGA_API_SECRET=$GA_API_SECRET ..
run: conda activate shapeworks && mkdir build && cd build && cmake -DCMAKE_LIBTOOL=/usr/bin/libtool -DCMAKE_CXX_FLAGS="-g -Wno-enum-constexpr-conversion" -DCMAKE_OSX_DEPLOYMENT_TARGET=$MACOSX_DEPLOYMENT_TARGET -DCMAKE_PREFIX_PATH=$HOME/install -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DPython3_ROOT_DIR:FILEPATH=${CONDA_PREFIX} -DUSE_OPENMP=OFF -DBuild_Studio=ON -DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/shapeworks-install -DBUILD_DOCUMENTATION=ON -DGA_MEASUREMENT_ID=$GA_MEASUREMENT_ID -DGA_API_SECRET=$GA_API_SECRET ..

- name: make
shell: bash -l {0}
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/build-mac.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release
MACOSX_DEPLOYMENT_TARGET: "12.0"
SW_CLOUD_LOGIN: ${{ secrets.CLOUD_LOGIN }}
CACHE_HOST: ${{ secrets.SSH_HOST }}
GA_MEASUREMENT_ID: ${{ secrets.GA_MEASUREMENT_ID }}
Expand Down Expand Up @@ -56,7 +57,7 @@ jobs:
uses: actions/cache/restore@v3
with:
path: /Users/runner/install
key: ${{ runner.os }}-intel-deps-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}
key: ${{ runner.os }}-intel-deps-osx${{ env.MACOSX_DEPLOYMENT_TARGET }}-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}

- name: Build Dependencies
shell: bash -l {0}
Expand All @@ -67,11 +68,11 @@ jobs:
uses: actions/cache/save@v3
with:
path: /Users/runner/install
key: ${{ runner.os }}-intel-deps-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}
key: ${{ runner.os }}-intel-deps-osx${{ env.MACOSX_DEPLOYMENT_TARGET }}-${{ hashFiles('.github/workflows/gha_deps.sh', 'install_shapeworks.sh', 'python_requirements.txt', 'build_dependencies.sh') }}

- name: cmake
shell: bash -l {0}
run: conda activate shapeworks && mkdir build && cd build && cmake -DCMAKE_LIBTOOL=/usr/bin/libtool -DCMAKE_CXX_FLAGS=-g -DCMAKE_PREFIX_PATH=$HOME/install -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DPython3_ROOT_DIR:FILEPATH=${CONDA_PREFIX} -DUSE_OPENMP=OFF -DBuild_Studio=ON -DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/shapeworks-install -DBUILD_DOCUMENTATION=OFF -DGA_MEASUREMENT_ID=$GA_MEASUREMENT_ID -DGA_API_SECRET=$GA_API_SECRET ..
run: conda activate shapeworks && mkdir build && cd build && cmake -DCMAKE_LIBTOOL=/usr/bin/libtool -DCMAKE_CXX_FLAGS=-g -DCMAKE_OSX_DEPLOYMENT_TARGET=$MACOSX_DEPLOYMENT_TARGET -DCMAKE_PREFIX_PATH=$HOME/install -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DPython3_ROOT_DIR:FILEPATH=${CONDA_PREFIX} -DUSE_OPENMP=OFF -DBuild_Studio=ON -DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/shapeworks-install -DBUILD_DOCUMENTATION=OFF -DGA_MEASUREMENT_ID=$GA_MEASUREMENT_ID -DGA_API_SECRET=$GA_API_SECRET ..

- name: make
shell: bash -l {0}
Expand Down
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ cmake_minimum_required(VERSION 3.20)
# SHAPEWORKS VERSION
###########################################
SET(SHAPEWORKS_MAJOR_VERSION 6 CACHE INTERNAL "Major version number" FORCE)
SET(SHAPEWORKS_MINOR_VERSION 7 CACHE INTERNAL "Minor version number" FORCE)
SET(SHAPEWORKS_MINOR_VERSION 8 CACHE INTERNAL "Minor version number" FORCE)
SET(SHAPEWORKS_PATCH_VERSION 0 CACHE INTERNAL "Patch version number" FORCE)
SET(SHAPEWORKS_VERSION_STRING "6.7.0-dev")
SET(SHAPEWORKS_VERSION_STRING "6.8.0-dev")
SET(SHAPEWORKS_VERSION "${SHAPEWORKS_MAJOR_VERSION}.${SHAPEWORKS_MINOR_VERSION}.${SHAPEWORKS_PATCH_VERSION}")

# First, check that files were checked out properly using git-lfs
Expand Down
2 changes: 1 addition & 1 deletion Installation/install_python_module.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# Ensures conda Python module is able to locate correct shapeworks_py binary module.


CONDA_INSTALL_DIR=`pip show shapeworks | grep Location | awk '{print $2}'`/shapeworks
CONDA_INSTALL_DIR=`python -m pip show shapeworks | grep Location | awk '{print $2}'`/shapeworks

# check if $CONDA_INSTALL_DIR is under $CONDA_PREFIX
if [[ "$CONDA_INSTALL_DIR" != "$CONDA_PREFIX"* ]]; then
Expand Down
2 changes: 1 addition & 1 deletion Libs/Application/Job/PythonWorker.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class PythonWorker : public QObject {
Q_OBJECT

public:
constexpr static const char* python_api_version = "6.7";
constexpr static const char* python_api_version = "6.8";

PythonWorker();
~PythonWorker();
Expand Down
2 changes: 1 addition & 1 deletion Python/shapeworks/shapeworks/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ def compute_line_indices(n, is_closed=True):


def get_api_version():
return "6.7"
return "6.8"


def set_sw_logger(log_object):
Expand Down
2 changes: 1 addition & 1 deletion devenv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# compiled portion of the Python bindings).
#

SW_MAJOR_VERSION=6.7
SW_MAJOR_VERSION=6.8

(return 0 2>/dev/null) && sourced=1 || sourced=0

Expand Down
8 changes: 7 additions & 1 deletion docs/dev/release-process.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ SET(SHAPEWORKS_VERSION "${SHAPEWORKS_MAJOR_VERSION}.${SHAPEWORKS_MINOR_VERSION}.

TODO - This should be automated from a single place

- `Studio/Python/PythonWorker.h`
- `Libs/Application/Job/PythonWorker.h`

```
constexpr static const char* python_api_version = "6.5";
Expand All @@ -46,6 +46,12 @@ python -c "import sys; print(sys.prefix)" > "%USERPROFILE%\.shapeworks\python_ho
echo %PATH% > "%USERPROFILE%\.shapeworks\path_6.5.txt"
```

- `devenv.sh`

```
SW_MAJOR_VERSION=6.5
```

* Update Release Notes

- Update `docs/about/release_notes.md` with the new release notes
Expand Down
6 changes: 3 additions & 3 deletions install_shapeworks.bat
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,9 @@ call .\Installation\install_python_module.bat || goto :error
call .\Installation\conda_env_setup.bat || goto :error

md "%USERPROFILE%\.shapeworks"
python -c "import sys; print('\n'.join(sys.path))" > "%USERPROFILE%\.shapeworks\python_path_6.7.txt"
python -c "import sys; print(sys.prefix)" > "%USERPROFILE%\.shapeworks\python_home_6.7.txt"
echo %PATH% > "%USERPROFILE%\.shapeworks\path_6.7.txt"
python -c "import sys; print('\n'.join(sys.path))" > "%USERPROFILE%\.shapeworks\python_path_6.8.txt"
python -c "import sys; print(sys.prefix)" > "%USERPROFILE%\.shapeworks\python_home_6.8.txt"
echo %PATH% > "%USERPROFILE%\.shapeworks\path_6.8.txt"
call conda info

REM === Validating installation ===
Expand Down
16 changes: 8 additions & 8 deletions install_shapeworks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Installs conda environment for building ShapeWorks
#

SW_MAJOR_VERSION=6.7
SW_MAJOR_VERSION=6.8

# Set up logging
INSTALL_LOG="install_shapeworks_$(date +%Y%m%d_%H%M%S).log"
Expand Down Expand Up @@ -173,7 +173,7 @@ function install_conda() {
if [[ $(uname -s) == "Darwin" ]] && [[ $(uname -m) == "x86_64" ]]; then
# Intel Mac - use older versions with NumPy 1.x
if ! python -m light_the_torch install torch==2.2.2 torchaudio==2.2.2 torchvision==0.17.2; then return 1; fi
pip install "numpy<2"
python -m pip install "numpy<2"
else
# Apple Silicon, Linux, Windows - use latest with NumPy 2.x support
if ! python -m light_the_torch install torch==2.8.0 torchaudio==2.8.0 torchvision==0.23.0; then return 1; fi
Expand All @@ -183,13 +183,13 @@ function install_conda() {
# open3d needs to be installed differently on each platform so it's not part of python_requirements.txt
OPEN3D_INSTALLED=NO
if [[ "$(uname)" == "Linux" ]]; then
if pip install open3d-cpu==0.19.0; then
if python -m pip install open3d-cpu==0.19.0; then
OPEN3D_INSTALLED=YES
else
echo "WARNING: open3d-cpu could not be installed. Network analysis features will not be available."
fi
elif [[ "$(uname)" == "Darwin" ]]; then
if pip install open3d==0.19.0; then
if python -m pip install open3d==0.19.0; then
OPEN3D_INSTALLED=YES
if [[ "$(uname -m)" == "arm64" ]]; then
pushd $CONDA_PREFIX/lib/python3.12/site-packages/open3d/cpu
Expand All @@ -202,7 +202,7 @@ function install_conda() {
echo "WARNING: open3d could not be installed. Network analysis features will not be available."
fi
else
if pip install open3d==0.19.0; then
if python -m pip install open3d==0.19.0; then
OPEN3D_INSTALLED=YES
else
echo "WARNING: open3d could not be installed. Network analysis features will not be available."
Expand All @@ -211,9 +211,9 @@ function install_conda() {

for package in DataAugmentationUtilsPackage DatasetUtilsPackage MONAILabelPackage DeepSSMUtilsPackage DocumentationUtilsPackage ShapeCohortGenPackage shapeworks ; do
if [[ -e Python/${package}.tar.gz ]] ; then
if ! pip install Python/${package}.tar.gz; then return 1; fi
if ! python -m pip install Python/${package}.tar.gz; then return 1; fi
else
if ! pip install Python/${package}; then return 1; fi
if ! python -m pip install Python/${package}; then return 1; fi
fi
done

Expand Down Expand Up @@ -270,7 +270,7 @@ if install_conda; then
conda list

echo "Pip installed packages:"
pip list
python -m pip list

conda clean -t -y

Expand Down
Loading