Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Clojure's approx= test function has a weakness #12320

Closed
taliesinb opened this issue Aug 23, 2018 · 3 comments
Closed

Clojure's approx= test function has a weakness #12320

taliesinb opened this issue Aug 23, 2018 · 3 comments
Labels

Comments

@taliesinb
Copy link
Contributor

Description

The clojure framework's approx= test utility function (defined in contrib/clojure-package/test/org/apache/clojure_mxnet/util_test.clj) is unable to detect differences between arrays if they are of different sizes and the difference occurs in the excess.

For example, this returns true, but should return false:

(approx= 1e-9 [1 1 1] [1 1 1 9 9 9])

This means that tests that use approx= in the clojure test suite can incorrectly succeed.

@taliesinb
Copy link
Contributor Author

I have fixed this in #12064.

@ankkhedia
Copy link
Contributor

@mxnet-label-bot [Clojure]

@gigasquid
Copy link
Member

Thanks @taliesinb 😸 - Closing this issue

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants