quiet keyword in Model class
gds38 opened this issue · 0 comments
gds38 commented
Should it be possible to set "quiet" as a kwarg in the Model class? I'd like to change it from the default False. The last piece of code in the init function makes it look like it's possible:
# Check the initial prior value
quiet = kwargs.get("quiet", False)
if not quiet and not np.isfinite(self.log_prior()):
raise ValueError("non-finite log prior value")
...but the preceding section (if len(kwargs:) raises the ValueError if you have set quiet as a kwarg:
else:
# Loop over the kwargs and set the parameter values
params = []
for k in self.parameter_names:
v = kwargs.pop(k, None)
if v is None:
raise ValueError("missing parameter '{0}'".format(k))
params.append(v)
self.parameter_vector = params
if len(kwargs):
raise ValueError("unrecognized parameter(s) '{0}'"
.format(list(kwargs.keys())))