Created by: kexinzhao
The code above returns a list of float scalars to test_metrics
as follows:
test_metrics = trainer.test(xxx)
Thus if we use avg_cost, acc = trainer.test(xxx)
instead, both avg_cost
and acc
would be a Python float scalar.
Hence we don't need the numpy.array(acc_set).mean()
and the code can be simplified.