Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
pinocchio
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Stack Of Tasks
pinocchio
Commits
3b2307c2
Commit
3b2307c2
authored
8 years ago
by
Nicolas Mansard
Committed by
Nicolas Mansard
8 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[C++] Introduce API for Data check.
parent
cc01159a
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
CMakeLists.txt
+1
-0
1 addition, 0 deletions
CMakeLists.txt
src/multibody/model.hpp
+21
-0
21 additions, 0 deletions
src/multibody/model.hpp
unittest/CMakeLists.txt
+1
-0
1 addition, 0 deletions
unittest/CMakeLists.txt
with
23 additions
and
0 deletions
CMakeLists.txt
+
1
−
0
View file @
3b2307c2
...
@@ -191,6 +191,7 @@ SET(${PROJECT_NAME}_ALGORITHM_HEADERS
...
@@ -191,6 +191,7 @@ SET(${PROJECT_NAME}_ALGORITHM_HEADERS
algorithm/frames.hpp
algorithm/frames.hpp
algorithm/compute-all-terms.hpp
algorithm/compute-all-terms.hpp
algorithm/copy.hpp
algorithm/copy.hpp
algorithm/check.hpp
)
)
SET
(
${
PROJECT_NAME
}
_PARSERS_HEADERS
SET
(
${
PROJECT_NAME
}
_PARSERS_HEADERS
...
...
This diff is collapsed.
Click to expand it.
src/multibody/model.hpp
+
21
−
0
View file @
3b2307c2
...
@@ -350,6 +350,9 @@ namespace se3
...
@@ -350,6 +350,9 @@ namespace se3
void
addJointIndexToParentSubtrees
(
const
JointIndex
joint_id
);
void
addJointIndexToParentSubtrees
(
const
JointIndex
joint_id
);
};
};
// Forward declaration needed for Data::check
template
<
class
D
>
struct
AlgorithmCheckerBase
;
struct
Data
struct
Data
{
{
EIGEN_MAKE_ALIGNED_OPERATOR_NEW
EIGEN_MAKE_ALIGNED_OPERATOR_NEW
...
@@ -505,6 +508,24 @@ namespace se3
...
@@ -505,6 +508,24 @@ namespace se3
///
///
Data
(
const
Model
&
model
);
Data
(
const
Model
&
model
);
/// Check the validity of the Data attributes with respect to the specification of some
/// algorithms.
///
/// The method is a template so that the checkers can be defined in each algorithms.
/// \param[in] checker a class, typically defined in the algorithm module, that
/// validates the attributes of data.
/// \return true if the Data are valid, false otherwise.
template
<
typename
D
>
inline
bool
check
(
const
AlgorithmCheckerBase
<
D
>
&
checker
)
{
return
checker
.
checkData
(
*
this
);
}
/// Multiple check for a fusion::vector of AlgorithmCheckerBase.
///
/// Run the check test for several conditons.
/// \param[in] v fusion::vector of algo checkers. The param is typically initialize with
/// boost::fusion::make_vector( AlgoChecker1(), AlgoChecker2(), ...)
template
<
typename
FusionVectorCheckers
>
bool
checkAll
(
const
FusionVectorCheckers
&
v
);
private
:
private
:
void
computeLastChild
(
const
Model
&
model
);
void
computeLastChild
(
const
Model
&
model
);
void
computeParents_fromRow
(
const
Model
&
model
);
void
computeParents_fromRow
(
const
Model
&
model
);
...
...
This diff is collapsed.
Click to expand it.
unittest/CMakeLists.txt
+
1
−
0
View file @
3b2307c2
...
@@ -114,3 +114,4 @@ ADD_UNIT_TEST(joint eigen3)
...
@@ -114,3 +114,4 @@ ADD_UNIT_TEST(joint eigen3)
ADD_UNIT_TEST
(
explog eigen3
)
ADD_UNIT_TEST
(
explog eigen3
)
ADD_UNIT_TEST
(
finite-differences eigen3
)
ADD_UNIT_TEST
(
finite-differences eigen3
)
ADD_UNIT_TEST
(
visitor eigen3
)
ADD_UNIT_TEST
(
visitor eigen3
)
ADD_UNIT_TEST
(
algo-check eigen3
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment