mirror of
https://github.com/romanz/amodem.git
synced 2026-04-18 12:16:00 +08:00
recv: remove saturation detection
This commit is contained in:
@@ -5,17 +5,6 @@ import logging
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
scaling = 32000.0 # out of 2**15
|
||||
SATURATION_THRESHOLD = (2**15 - 1) / scaling
|
||||
|
||||
|
||||
class SaturationError(ValueError):
|
||||
pass
|
||||
|
||||
|
||||
def check_saturation(x):
|
||||
peak = np.max(np.abs(x))
|
||||
if peak >= SATURATION_THRESHOLD:
|
||||
raise SaturationError(peak)
|
||||
|
||||
|
||||
def load(fileobj):
|
||||
|
||||
Reference in New Issue
Block a user