AssertionError: Sum of activate marks must be a multiple of 50
I am getting this error when running this test. Not sure what is going on. Thx.
def create_training_example_test(target):
np.random.seed(18)
x, y = target(backgrounds[0], activates, negatives, 1375)
assert type(x) == np.ndarray, "Wrong type for x"
assert type(y) == np.ndarray, "Wrong type for y"
assert tuple(x.shape) == (101, 5511), "Wrong shape for x"
assert tuple(y.shape) == (1, 1375), "Wrong shape for y"
assert np.all(x > 0), "All x values must be higher than 0"
assert np.all(y >= 0), "All y values must be higher or equal than 0"
assert np.all(y <= 1), "All y values must be smaller or equal than 1"
assert np.sum(y) >= 50, "It must contain at least one activate"
assert np.sum(y) % 50 == 0, "Sum of activate marks must be a multiple of 50"
assert np.isclose(np.linalg.norm(x), 39745552.52075), "Spectrogram is wrong. Check the parameters passed to the insert_audio_clip function"
print("\033[92m All tests passed!")
create_training_example_test(create_training_example)