diff options
Diffstat (limited to 'src/python')
-rwxr-xr-x | src/python/test/test_dtm.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/python/test/test_dtm.py b/src/python/test/test_dtm.py index 8d400c7e..0a52279e 100755 --- a/src/python/test/test_dtm.py +++ b/src/python/test/test_dtm.py @@ -84,5 +84,6 @@ def test_density(): assert density == pytest.approx(expected) distances = [[0, 1], [2, 0], [1, 3]] density = DTMDensity(metric="neighbors", dim=1).fit_transform(distances) - expected = numpy.array([2.0, 1.0, 0.5]) + assert density == pytest.approx(expected) + density = DTMDensity(weights=[0.5, 0.5], metric="neighbors", dim=1).fit_transform(distances) assert density == pytest.approx(expected) |