Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions cpp/zimt/pyohrli_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import numpy as np

import unittest
import pyohrli
import cpp.zimt.zimtohrli as zimtohrli
import functools


Expand All @@ -35,10 +35,10 @@ def call_with_parameters(self, **inner_kwargs):
class PyohrliTest(unittest.TestCase):

def test_num_rotators(self):
self.assertEqual(128, pyohrli.Pyohrli().num_rotators)
self.assertEqual(128, zimtohrli.Pyohrli().num_rotators)

def test_sample_rate(self):
self.assertEqual(48000, pyohrli.Pyohrli().sample_rate)
self.assertEqual(48000, zimtohrli.Pyohrli().sample_rate)

@parameterize(
dict(
Expand All @@ -59,7 +59,7 @@ def test_sample_rate(self):
)
def test_distance(self, a_hz: float, b_hz: float, distance: float):
sample_rate = 48000.0
metric = pyohrli.Pyohrli()
metric = zimtohrli.Pyohrli()
signal_a = np.sin(np.linspace(0.0, np.pi * 2 * a_hz, int(sample_rate)))
signal_b = np.sin(np.linspace(0.0, np.pi * 2 * b_hz, int(sample_rate)))
distance = metric.distance(signal_a, signal_b)
Expand All @@ -75,7 +75,7 @@ def test_distance(self, a_hz: float, b_hz: float, distance: float):
)
def test_mos_from_zimtohrli(self, zimtohrli_distance: float, mos: float):
self.assertAlmostEqual(
mos, pyohrli.mos_from_zimtohrli(zimtohrli_distance), places=3
mos, zimtohrli.mos_from_zimtohrli(zimtohrli_distance), places=3
)


Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def build_extensions(self):
super().build_extensions()

setup(
name='pyohrli',
name='zimtohrli',
version='0.2.1',
author='Martin Bruse, Jyrki Alakuijala',
author_email='zond@google.com, jyrki@google.com',
Expand All @@ -28,7 +28,7 @@ def build_extensions(self):
],
package_dir={'': 'cpp/zimt'},
packages=find_packages(where='cpp/zimt'),
py_modules=['pyohrli'],
py_modules=['zimtohrli'],
ext_modules=[
Extension(
name='_pyohrli',
Expand Down
Loading