Skip to content

Commit

Permalink
Fix python tests for SDF internals
Browse files Browse the repository at this point in the history
  • Loading branch information
clbarnes committed Jan 10, 2024
1 parent 2e6ef5e commit 6138656
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down
6 changes: 3 additions & 3 deletions tests/test_ncollpyde.py
Original file line number Diff line number Diff line change
Expand Up @@ -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):
Expand Down

0 comments on commit 6138656

Please sign in to comment.