Skip to content

Commit

Permalink
Merge branch 'devel' into dependabot/github_actions/conda-incubator/s…
Browse files Browse the repository at this point in the history
…etup-miniconda-3
  • Loading branch information
jcarpent authored Dec 11, 2023
2 parents 3f1457b + 9c2e38c commit 58ffc58
Show file tree
Hide file tree
Showing 9 changed files with 45 additions and 21 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/ros-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,10 @@ jobs:
strategy:
matrix:
env:
- {ROS_DISTRO: noetic}
- {ROS_DISTRO: rolling, BUILDER: colcon}
- {ROS_DISTRO: noetic, BUILDER: catkin_tools}
- {ROS_DISTRO: rolling}
- {ROS_DISTRO: iron}
- {ROS_DISTRO: humble}
env:
CCACHE_DIR: /github/home/.ccache # Enable ccache
CTEST_OUTPUT_ON_FAILURE: ON
Expand All @@ -25,7 +27,6 @@ jobs:
# The work-around is thus to use catkin_tools for building and sourcing, and to manually specify execution of the test
# target after completion of the regular test target. The output of this step does affect the output of the CI process.
# Note, this does not affect projects that do not have pure CMake projects in their upstream_ws.
BUILDER: catkin_tools
AFTER_RUN_TARGET_TEST: 'ici_with_unset_variables source /root/target_ws/install/setup.bash && cd /root/target_ws/build/pinocchio && make test'
IMMEDIATE_TEST_OUTPUT: 1
runs-on: ubuntu-latest
Expand Down
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

## [Unreleased]

### Fixed

- Use bp::ssize_t for recent version of Windows compilers ([#2102](https://github.com/stack-of-tasks/pinocchio/pull/2102))
- Fix missing include for Boost >= 1.83 ([#2103](https://github.com/stack-of-tasks/pinocchio/pull/2103))
- Remove f-strings to fix install with python 2 ([#2110](https://github.com/stack-of-tasks/pinocchio/pull/2110))
- CMake: stop exporting CppAd/cppadcodegen & fetch submodule if not available ([#2112](https://github.com/stack-of-tasks/pinocchio/pull/2112))

## [2.6.21] - 2023-11-27

### Added
Expand Down
33 changes: 24 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,20 +24,35 @@ OPTION(INSTALL_DOCUMENTATION "Generate and install the documentation" OFF)

# Check if the submodule cmake have been initialized
set(JRL_CMAKE_MODULES "${CMAKE_CURRENT_LIST_DIR}/cmake")
IF(NOT EXISTS "${JRL_CMAKE_MODULES}/base.cmake")
MESSAGE(FATAL_ERROR "\nPlease run the following command first:\ngit submodule update --init\n")
ENDIF()
if(NOT EXISTS "${JRL_CMAKE_MODULES}/base.cmake")
if(${CMAKE_VERSION} VERSION_LESS "3.14.0")
message(
FATAL_ERROR
"\nPlease run the following command first:\ngit submodule update --init\n"
)
else()
message(STATUS "JRL cmakemodules not found. Let's fetch it.")
include(FetchContent)
FetchContent_Declare(
"jrl-cmakemodules"
GIT_REPOSITORY "https://github.com/jrl-umi3218/jrl-cmakemodules.git")
FetchContent_MakeAvailable("jrl-cmakemodules")
FetchContent_GetProperties("jrl-cmakemodules" SOURCE_DIR JRL_CMAKE_MODULES)
endif()
endif()


SET(DOXYGEN_USE_MATHJAX YES)
SET(DOXYGEN_USE_TEMPLATE_CSS YES)

INCLUDE(${CMAKE_CURRENT_LIST_DIR}/cmake/base.cmake)
INCLUDE("${JRL_CMAKE_MODULES}/base.cmake")

COMPUTE_PROJECT_ARGS(PROJECT_ARGS LANGUAGES CXX)
PROJECT(${PROJECT_NAME} ${PROJECT_ARGS})

INCLUDE(${CMAKE_CURRENT_LIST_DIR}/cmake/boost.cmake)
INCLUDE(${CMAKE_CURRENT_LIST_DIR}/cmake/ide.cmake)
INCLUDE(${CMAKE_CURRENT_LIST_DIR}/cmake/apple.cmake)
INCLUDE("${JRL_CMAKE_MODULES}/boost.cmake")
INCLUDE("${JRL_CMAKE_MODULES}/ide.cmake")
INCLUDE("${JRL_CMAKE_MODULES}/apple.cmake")
IF(APPLE) # Use the handmade approach
SET(CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR}/cmake/find-external/OpenMP ${CMAKE_MODULE_PATH})
ENDIF(APPLE)
Expand Down Expand Up @@ -120,10 +135,10 @@ ENDIF(BUILD_WITH_URDF_SUPPORT)
IF(BUILD_WITH_AUTODIFF_SUPPORT)
# Check first CppADCodeGen
IF(BUILD_WITH_CODEGEN_SUPPORT)
ADD_PROJECT_DEPENDENCY(cppadcg 2.4.1 REQUIRED PKG_CONFIG_REQUIRES "cppadcg >= 2.4.1") # CppADCodeGen 2.4.1 is the first version to check the minimal version of CppAD
FIND_PACKAGE(cppadcg 2.4.1 REQUIRED)
ENDIF(BUILD_WITH_CODEGEN_SUPPORT)

ADD_PROJECT_DEPENDENCY(cppad 20180000.0 REQUIRED PKG_CONFIG_REQUIRES "cppad >= 20180000.0")
FIND_PACKAGE(cppad 20180000.0 REQUIRED)
ENDIF(BUILD_WITH_AUTODIFF_SUPPORT)

IF(BUILD_WITH_CASADI_SUPPORT)
Expand Down
4 changes: 2 additions & 2 deletions bindings/python/pinocchio/visualize/meshcat_visualizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -618,7 +618,7 @@ def initializeFrames(self, frame_ids=None, axis_length=0.2, axis_width=2):

for fid, frame in enumerate(self.model.frames):
if frame_ids is None or fid in frame_ids:
frame_viz_name = f"{self.viewerFramesGroupName}/{frame.name}"
frame_viz_name = "%s/%s" % (self.viewerFramesGroupName, frame.name)
self.viewer[frame_viz_name].set_object(
mg.LineSegments(
mg.PointsGeometry(
Expand All @@ -640,7 +640,7 @@ def updateFrames(self):
pin.updateFramePlacements(self.model, self.data)
for fid in self.frame_ids:
frame_name = self.model.frames[fid].name
frame_viz_name = f"{self.viewerFramesGroupName}/{frame_name}"
frame_viz_name = "%s/%s" % (self.viewerFramesGroupName, frame_name)
self.viewer[frame_viz_name].set_transform(
self.data.oMf[fid].homogeneous
)
Expand Down
2 changes: 1 addition & 1 deletion bindings/python/utils/conversions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ namespace pinocchio
template <typename TupleOrList>
SE3 XYZQUATToSE3_bp(const TupleOrList& v)
{
ssize_t size = bp::len(v);
bp::ssize_t size = bp::len(v);
if(size != 7)
{
throw std::invalid_argument(
Expand Down
2 changes: 1 addition & 1 deletion cmake
Submodule cmake updated 2 files
+9 −0 cxx-standard.cmake
+1 −1 test.cmake
2 changes: 1 addition & 1 deletion examples/update-model-after-urdf.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@


def check_limb_lengths(limb_length: float) -> bool:
print(f"Checking that limbs are {limb_length} m long... ", end="")
print("Checking that limbs are %s m long... " % limb_length, end="")
for side in ("left", "right"):
for joint in ("knee", "wheel"):
joint_id = model.getJointId(f"{side}_{joint}")
Expand Down
1 change: 1 addition & 0 deletions include/pinocchio/math/fwd.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
#include "pinocchio/fwd.hpp"
#include <math.h>
#include <boost/math/constants/constants.hpp>
#include <boost/type_traits/is_floating_point.hpp>

namespace pinocchio
{
Expand Down
8 changes: 4 additions & 4 deletions package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
<build_depend>doxygen</build_depend>
<doc_depend>doxygen</doc_depend>
<doc_depend>texlive-latex-base</doc_depend>
<!-- Required for the environment variables (ROS_VERSION, ROS_DISTRO) to be available -->
<depend>ros_environment</depend>
<!-- The following tags are recommended by REP-136 -->
<exec_depend condition="$ROS_VERSION == 1">catkin</exec_depend>
<depend condition="$ROS_PYTHON_VERSION == 2">python</depend>
<depend condition="$ROS_PYTHON_VERSION == 3">python3</depend>
<depend condition="$ROS_PYTHON_VERSION == 2">python-numpy</depend>
<depend condition="$ROS_PYTHON_VERSION == 3">python3-numpy</depend>
<depend>python3</depend>
<depend>python3-numpy</depend>
<depend>liburdfdom-dev</depend>
<depend>eigen</depend>
<depend>boost</depend>
Expand Down

0 comments on commit 58ffc58

Please sign in to comment.