Update UT test_boxps (#19599)

Disable test_boxps in win32.
Adjust filename to avoid latent multi-thread problem.
fix_crf_doc
hutuxian 6 years ago committed by GitHub
parent f2ad30c4dd
commit 66ad68ed7b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -35,6 +35,10 @@ if(NOT WITH_GPU OR WIN32)
LIST(REMOVE_ITEM TEST_OPS test_reducescatter)
endif()
if(WIN32)
LIST(REMOVE_ITEM TEST_OPS test_boxps)
endif()
LIST(REMOVE_ITEM TEST_OPS test_launch)
if (NOT ${WITH_GPU})

@ -58,8 +58,9 @@ class TestBoxPSPreload(unittest.TestCase):
batch1 = np.ones(
(batch_size, 2, 1)).astype("int64").reshape(batch_size, 2, 1)
filelist = []
place_str = "cpu" if is_cpu else "gpu"
for i in range(2):
filelist.append("test_hdfs_" + str(i))
filelist.append("test_hdfs_" + place_str + "_" + str(i))
for f in filelist:
with open(f, "w") as fout:
for ins in batch1:

Loading…
Cancel
Save