Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_chord_length_distribution_2D(self):
chords = ps.filters.apply_chords(self.im2D)
ps.metrics.chord_length_distribution(chords, normalization='length')
def test_chord_length_distribution_3D(self):
chords = ps.filters.apply_chords(self.im3D)
ps.metrics.chord_length_distribution(chords, normalization='length')
def test_apply_chords_axis2(self):
c = ps.filters.apply_chords(im=self.im, spacing=3, axis=2)
assert c.sum() == 23752
c = ps.filters.apply_chords(im=self.im, axis=2)
assert c.sum() == 103347
def test_apply_chords_axis2(self):
c = ps.filters.apply_chords(im=self.im, spacing=3, axis=2)
assert c.sum() == 23752
c = ps.filters.apply_chords(im=self.im, axis=2)
assert c.sum() == 103347
def test_apply_chords_without_trimming(self):
c = ps.filters.apply_chords(im=self.im, trim_edges=False)
assert c.sum() == 125043
c = ps.filters.apply_chords(im=self.im, spacing=3, trim_edges=False)
assert c.sum() == 31215
def test_apply_chords_axis1(self):
c = ps.filters.apply_chords(im=self.im, spacing=3, axis=1)
assert c.sum() == 23422
c = ps.filters.apply_chords(im=self.im, axis=1)
assert c.sum() == 102205