コード例 #1
0
ファイル: conftest.py プロジェクト: tondzus/mnisttk
def xor_dataset(resources_root):
    xor_dataset_path = join(resources_root, 'xor_dataset.idx')
    return mnisttk.decode(xor_dataset_path)
コード例 #2
0
ファイル: test_idx_parser.py プロジェクト: tondzus/mnisttk
def test_matrix_file_load_helper(ubyte_matrix):
    matrix = mnisttk.decode(ubyte_matrix)
    assert matrix.dtype == np.uint8
    assert matrix.shape == (2, 3)
    assert np.all(matrix.reshape(6) == [1, 2, 3, 4, 5, 6])
コード例 #3
0
ファイル: conftest.py プロジェクト: tondzus/mnisttk
def and_dataset(resources_root):
    and_dataset_path = join(resources_root, 'and_dataset.idx')
    return mnisttk.decode(and_dataset_path)