3f2ce7b3847950a299e25861b20b5964f117daab,tests/test_loom_metamodel.py,,test_loom_three_var,#,31

Before Change


X_MIN, Y_MIN = 0, 0
X_MAX, Y_MAX = 200, 100
def test_loom_three_var():
    prng = random.Random(time.time())
    with bayesdb_open(":memory:") as bdb:
        bayesdb_register_metamodel(bdb, LoomMetamodel())
        bdb.sql_execute("create table t(x, xx, y, z)")
        bdb.sql_execute("insert into t(x, xx, y, z) values(100, 200, 50, "a")")

After Change


            x = bdb._prng.weakrandom_uniform(X_MAX)
            bdb.sql_execute("insert into t(x, xx, y, z) values(?, ?, ?, ?)",
                    (x, x*2,
                        int(bdb._prng.weakrandom_uniform(Y_MAX)),
                        "a" if bdb._prng.weakrandom_uniform(2) == 1 else "b"))

        bdb.execute("create population p for t(x numerical; xx numerical; y numerical; z categorical)")
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: probcomp/bayeslite
Commit Name: 3f2ce7b3847950a299e25861b20b5964f117daab
Time: 2017-07-12
Author: michael_truell@horacemann.org
File Name: tests/test_loom_metamodel.py
Class Name:
Method Name: test_loom_three_var


Project Name: lufficc/SSD
Commit Name: b65560304dc61e63fa45e5a26fee930661c6e998
Time: 2019-06-23
Author: luffy.lcc@gmail.com
File Name: ssd/engine/trainer.py
Class Name:
Method Name: do_train


Project Name: andresriancho/w3af
Commit Name: a0a4fd099e664bcbbd207df1368e9ce8d947a407
Time: 2018-07-21
Author: andres.riancho@gmail.com
File Name: w3af/core/controllers/core_helpers/status.py
Class Name: CoreStatus
Method Name: get_progress_percentage