Closed AmeliaFord353 closed 9 months ago
Can I check whether these are actually being raised as errors or whether you are just getting things printed such as 0.0 cannot be raised to a negative power
? If the latter, then this is just from printing the exception (but still catching it) in fitting.test_all
. I have removed this print statement in the branch associated with this issue. If the former, can you give me an example of where this causes an error rather than just printing the warning?
Having just looked at the output file you sent me, it appears that the issue was being raised in match
and not test_all
. I've now put the try-except statement you suggested in. Please can you check whether this has fixed your issue?
Hi Deaglan,
Thank you - I'll run this now. I don't know if it will be completed by the time by the meeting at 3pm but I should at least have enough of an output to see if any errors are being thrown.
Thanks,
From: Deaglan Bartlett @.> Sent: 20 September 2023 13:34 To: DeaglanBartlett/ESR @.> Cc: AmeliaFord353 @.>; Author @.> Subject: Re: [DeaglanBartlett/ESR] get_pred() exception handling in likelihood class (Issue #27)
Having just looked at the output file you sent me, it appears that the issue was being raised in match and not test_all. I've now put the try-except statement you suggested in. Please can you check whether this has fixed your issue?
— Reply to this email directly, view it on GitHubhttps://github.com/DeaglanBartlett/ESR/issues/27#issuecomment-1727634272, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BBUWILJH3ZHN47KLZVNY4DTX3LPELANCNFSM6AAAAAA4SH4TTE. You are receiving this because you authored the thread.Message ID: @.***>
Hi @AmeliaFord353! Did this fix solve your problem?
Yes, thank you!
In the likelihood class in likelihood.py, there are errors being caused when trying to determine y values for functions, such as divide by zero. These are being produced in get_pred(). Possibly the code needs an exception handling if y cannot be calculated, or a process to drop the problematic functions altogether?