MCPcopy
hub / github.com/shenweichen/DeepCTR-Torch / test_AFN

Function test_AFN

tests/models/AFN_test.py:14–22  ·  view source on GitHub ↗
(afn_dnn_hidden_units, sparse_feature_num, dense_feature_num)

Source from the content-addressed store, hash-verified

12 ((32, 16), 0, 3)]
13)
14def test_AFN(afn_dnn_hidden_units, sparse_feature_num, dense_feature_num):
15 model_name = 'AFN'
16 sample_size = SAMPLE_SIZE
17 x, y, feature_columns = get_test_data(
18 sample_size, sparse_feature_num=sparse_feature_num, dense_feature_num=dense_feature_num)
19
20 model = AFN(feature_columns, feature_columns, afn_dnn_hidden_units=afn_dnn_hidden_units, device=get_device())
21
22 check_model(model, model_name, x, y)
23
24
25if __name__ == '__main__':

Callers

nothing calls this directly

Calls 4

get_test_dataFunction · 0.90
AFNClass · 0.90
get_deviceFunction · 0.90
check_modelFunction · 0.90

Tested by

no test coverage detected