Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Understanding the "equality_check" parameter in perfplot #92

Closed
ghost opened this issue Dec 2, 2020 · 1 comment
Closed

Understanding the "equality_check" parameter in perfplot #92

ghost opened this issue Dec 2, 2020 · 1 comment

Comments

@ghost
Copy link

ghost commented Dec 2, 2020

A question regarding the "equality_check" criteria. Could someone please explain to me its significance? I don't quite understand what it's exactly used for. In many instances, without having it set to "None", I would get this error: "AssertionError: Equality check failure". Thus I generally tend to keep it as "equality_check=None".

I'm not quite sure what it's doing behind the scenes, so could someone please give it some context and explain it in brief? #

@nschloe
Copy link
Owner

nschloe commented Dec 2, 2020

perfplot is often used to compare pieces of code "that do the same". To make sure they really do, you typically return something from each of the kernels, and those results are then checked for equality.

In some cases, you're not interested in the result, so you just set the equality_check to None. (Or don't return anything from any function.)

@nschloe nschloe closed this as completed Dec 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant