test
This commit is contained in:
parent
e8945f2b00
commit
2edac8dab0
|
@ -0,0 +1,28 @@
|
|||
|
||||
import test_net
|
||||
import object
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
# add objects for searching
|
||||
objs = [
|
||||
|
||||
|
||||
"param_dict=load_checkpoint(",
|
||||
"load_param_into_net(network,param_dict)",
|
||||
"ds_eval=create_dataset(os.path.join(mnist_path,",
|
||||
"acc=model.eval(ds_eval, dataset_sink_mode=False)"
|
||||
|
||||
|
||||
]
|
||||
|
||||
filepath = "./MindSpore/src/step4/test_net.py"
|
||||
|
||||
if (object.objectFind(objs, filepath)):
|
||||
print("----------------")
|
||||
|
||||
print("ok!")
|
||||
else:
|
||||
print("object error!")
|
||||
|
||||
|
Loading…
Reference in New Issue