From 6138656561f38584a9c8f386f49d78ec28201c10 Mon Sep 17 00:00:00 2001 From: Chris Barnes Date: Wed, 10 Jan 2024 17:02:41 +0000 Subject: [PATCH] Fix python tests for SDF internals --- src/utils.rs | 2 +- tests/test_ncollpyde.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/utils.rs b/src/utils.rs index 8b74549..5594583 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -2,7 +2,7 @@ use ndarray::ArrayView1; use parry3d_f64::math::{Point, Vector}; use parry3d_f64::na::{distance, Unit}; use parry3d_f64::query::{PointQuery, Ray, RayCast}; -use parry3d_f64::shape::{FeatureId, Shape, TriMesh, TriMeshFlags}; +use parry3d_f64::shape::{FeatureId, TriMesh, TriMeshFlags}; use rand::Rng; pub type Precision = f64; diff --git a/tests/test_ncollpyde.py b/tests/test_ncollpyde.py index 6205289..2130375 100644 --- a/tests/test_ncollpyde.py +++ b/tests/test_ncollpyde.py @@ -325,9 +325,9 @@ def test_configure_threadpool_twice(): @pytest.mark.parametrize( ["point", "vec", "exp_dist", "exp_dot"], [ - ([0.5, 0.5, 0.5], [1, 0, 0], 0.5, -1), - ([-0.5, 0.5, 0.5], [1, 0, 0], -0.5, -1), - ([0.75, 0.5, 0.5], [1, 1, 0], sqrt(2 * 0.25**2), -np.cos(pi / 4)), + ([0.5, 0.5, 0.5], [1, 0, 0], 0.5, 1), + ([-0.5, 0.5, 0.5], [1, 0, 0], -0.5, 1), + ([0.75, 0.5, 0.5], [1, 1, 0], sqrt(2 * 0.25**2), np.cos(pi / 4)), ], ) def test_sdf_inner(simple_volume: Volume, point, vec, exp_dist, exp_dot):