Skip to content
Snippets Groups Projects
Commit cb005905 authored by Kipp Cannon's avatar Kipp Cannon
Browse files

SNRPDF: add input checks to .__init__()

parent 624a3946
No related branches found
No related tags found
No related merge requests found
......@@ -343,6 +343,10 @@ class SNRPDF(object):
impossible to obtain a candidate (the trigger SNR
threshold).
"""
if log_distance_tolerance <= 0.:
raise ValueError("require log_distance_tolerance > 0")
if not 0. <= min_ratio < 1.:
raise ValueError("require 0 <= min_ratio < 1")
self.snr_cutoff = snr_cutoff
self.log_distance_tolerance = log_distance_tolerance
self.min_ratio = min_ratio
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment