MCPcopy Create free account
hub / github.com/numpy/numpy / test_large_integers

Method test_large_integers

numpy/lib/tests/test_histograms.py:770–780  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

768 assert_equal(edges[1].dtype, y_edges.dtype)
769
770 def test_large_integers(self):
771 big = 2**60 # Too large to represent with a full precision float
772
773 x = np.array([0], np.int64)
774 x_edges = np.array([-1, +1], np.int64)
775 y = big + x
776 y_edges = big + x_edges
777
778 hist, edges = histogramdd((x, y), bins=(x_edges, y_edges))
779
780 assert_equal(hist[0, 0], 1)
781
782 def test_density_non_uniform_2d(self):
783 # Defines the following grid:

Callers

nothing calls this directly

Calls 2

histogramddFunction · 0.90
assert_equalFunction · 0.90

Tested by

no test coverage detected