Skip to content

Commit

Permalink
Fix detection of sources outside the room
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidDiazGuerra authored Feb 24, 2020
1 parent 2456725 commit c2e7f6e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gpuRIR/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,8 @@ def simulateRIR(room_sz, beta, pos_src, pos_rcv, nb_img, Tmax, fs, Tdiff=None, m
the GPU memory and crash the kernel.
'''
assert np.sum(pos_src >= room_sz) == 0, "The sources must be inside the room"
assert np.sum(pos_rcv >= room_sz) == 0, "The receivers must be inside the room"
assert not ((pos_src >= room_sz).any() or (pos_src <= 0).any()), "The sources must be inside the room"
assert not ((pos_rcv >= room_sz).any() or (pos_rcv <= 0).any()), "The receivers must be inside the room"
assert Tdiff is None or Tdiff <= Tmax, "Tmax must be equal or greater than Tdiff"
assert mic_pattern in mic_patterns, "mic_pattern must be omni, homni, card, hypcard, subcard or bidir"
assert mic_pattern is "omni" or orV_rcv is not None, "the mics are not omni but their orientation is undefined"
Expand Down

0 comments on commit c2e7f6e

Please sign in to comment.