File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed
src/autora/experimentalist/falsification Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -240,13 +240,14 @@ def sample(
240240
241241 # get target pattern for popper net
242242 model_predict = getattr (model , "predict_proba" , None )
243- if callable (model_predict ) is False :
244- model_predict = getattr (model , "predict" , None )
245-
246243 if callable (model_predict ) is False or model_predict is None :
247- raise Exception ("Model must have `predict` or `predict_proba` method." )
244+ model_predict = getattr (model , "predict" , None )
245+ if callable (model_predict ) is False or model_predict is None :
246+ raise Exception ("Model must have `predict` or `predict_proba` method." )
247+ else :
248+ predicted_observations = model .predict (reference_conditions )
248249 else :
249- predicted_observations = model .predict (reference_conditions )
250+ predicted_observations = model .predict_proba (reference_conditions )
250251
251252 if isinstance (predicted_observations , np .ndarray ) is False :
252253 try :
You can’t perform that action at this time.
0 commit comments