MCPcopy
hub / github.com/hyperopt/hyperopt / test_offgrid_int

Method test_offgrid_int

hyperopt/tests/unit/test_rdists.py:119–125  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

117 check_d_samples(qu, n=10000)
118
119 def test_offgrid_int(self):
120 qn = quniform_gen(0, 2, 2)
121 assert qn.pmf(0) > 0.0
122 assert qn.pmf(1) == 0.0
123 assert qn.pmf(2) > 0.0
124 assert qn.pmf(3) == 0.0
125 assert qn.pmf(-1) == 0.0
126
127 def test_offgrid_float(self):
128 qn = quniform_gen(0, 1, 0.2)

Callers

nothing calls this directly

Calls 2

quniform_genClass · 0.90
pmfMethod · 0.45

Tested by

no test coverage detected