chrishkchris commented on issue #672: Add mean square error back and fix test case URL: https://github.com/apache/singa/pull/672#issuecomment-611491678 Here I also post the test for USE_CUDA=ON and USE_DIST=ON for reference. ``` root@71ac539cda77:~/dcsysh/singa/test/python# python3 run.py .......................................................TEST CONV2D FORWARD TEST CONV2D DATA BACKWARD TEST CONV2D WEIGHT BACKWARD TEST CONV2D DATA BACKWARD [2.0000002] ..............('relu1', (2,)) ('relu2', (2,)) ('merge', [(2,), (2,)]) .('relu1', (2,)) ('relu2', (2,)) ('merge', [(2,), (2,)]) ('split', [(2,), (2,)]) ('split1', (2,)) ('split2', (2,)) .('conv', (4, 12, 12)) ('flat', (576,)) ('dense', (4,)) NOTE: If your model was saved using pickle, then set use_pickle=True for loading it NOTE: If your model was saved using Snapshot, then set use_pickle=False for loading it .('relu1', (2,)) ('relu2', (2,)) .('conv', (4, 12, 12)) ('flat', (576,)) ('dense', (4,)) ............................................................................................................................................................................................................................/root/dcsysh/singa/test/python/test_onnx_backend.py:1871: RuntimeWarning: divide by zero encountered in power z = np.power(x, y) .................................................................................................................................................................................................................................................................................. ---------------------------------------------------------------------- Ran 567 tests in 4.135s OK root@71ac539cda77:~/dcsysh/singa/build/bin# ./test_singa Running main() from gtest_main.cc [==========] Running 257 tests from 49 test cases. [----------] Global test environment set-up. [----------] 1 test from Accuracy [ RUN ] Accuracy.Compute [ OK ] Accuracy.Compute (0 ms) [----------] 1 test from Accuracy (0 ms total) [----------] 3 tests from Activation [ RUN ] Activation.Setup [ OK ] Activation.Setup (0 ms) [ RUN ] Activation.Forward [ OK ] Activation.Forward (0 ms) [ RUN ] Activation.Backward [ OK ] Activation.Backward (0 ms) [----------] 3 tests from Activation (0 ms total) [----------] 2 tests from AdaGrad [ RUN ] AdaGrad.ApplyCPU [ OK ] AdaGrad.ApplyCPU (0 ms) [ RUN ] AdaGrad.ApplyCUDA [ OK ] AdaGrad.ApplyCUDA (2350 ms) [----------] 2 tests from AdaGrad (2351 ms total) [----------] 3 tests from BatchNorm [ RUN ] BatchNorm.Setup [ OK ] BatchNorm.Setup (0 ms) [ RUN ] BatchNorm.Forward [ OK ] BatchNorm.Forward (0 ms) [ RUN ] BatchNorm.Backward [ OK ] BatchNorm.Backward (0 ms) [----------] 3 tests from BatchNorm (0 ms total) [----------] 2 tests from BinFileWriter [ RUN ] BinFileWriter.Create [ OK ] BinFileWriter.Create (4 ms) [ RUN ] BinFileWriter.Append [ OK ] BinFileWriter.Append (3 ms) [----------] 2 tests from BinFileWriter (7 ms total) [----------] 2 tests from BinFileReader [ RUN ] BinFileReader.Read [ OK ] BinFileReader.Read (1 ms) [ RUN ] BinFileReader.SeekToFirst [ OK ] BinFileReader.SeekToFirst (1 ms) [----------] 2 tests from BinFileReader (2 ms total) [----------] 3 tests from Channel [ RUN ] Channel.InitChannel [ OK ] Channel.InitChannel (0 ms) [ RUN ] Channel.SendStringToFile [W d0409 t11:43:33 p25776:416 /root/dcsysh/singa/src/utils/channel.cc:70] Messages will be appended to an existed file: /tmp/test_channel [ OK ] Channel.SendStringToFile (0 ms) [ RUN ] Channel.SendStringToFileAndStderr test to both file and stderr [ OK ] Channel.SendStringToFileAndStderr (0 ms) [----------] 3 tests from Channel (0 ms total) [----------] 9 tests from Concat [ RUN ] Concat.Setup [ OK ] Concat.Setup (0 ms) [ RUN ] Concat.ForwardConcatRowCpp [ OK ] Concat.ForwardConcatRowCpp (0 ms) [ RUN ] Concat.ForwardConcatColumnCpp [ OK ] Concat.ForwardConcatColumnCpp (0 ms) [ RUN ] Concat.ForwardConcatRowCuda [ OK ] Concat.ForwardConcatRowCuda (10 ms) [ RUN ] Concat.ForwardConcatColumnCuda [ OK ] Concat.ForwardConcatColumnCuda (12 ms) [ RUN ] Concat.BackwardConcatRowCpp [ OK ] Concat.BackwardConcatRowCpp (0 ms) [ RUN ] Concat.BackwardConcatColumn [ OK ] Concat.BackwardConcatColumn (0 ms) [ RUN ] Concat.BackwardConcatRowCuda [ OK ] Concat.BackwardConcatRowCuda (15 ms) [ RUN ] Concat.BackwardConcatColumnCuda [ OK ] Concat.BackwardConcatColumnCuda (13 ms) [----------] 9 tests from Concat (50 ms total) [----------] 3 tests from Convolution [ RUN ] Convolution.Setup [ OK ] Convolution.Setup (0 ms) [ RUN ] Convolution.Forward [ OK ] Convolution.Forward (0 ms) [ RUN ] Convolution.Backward [ OK ] Convolution.Backward (0 ms) [----------] 3 tests from Convolution (1 ms total) [----------] 4 tests from CppCPU [ RUN ] CppCPU.Constructor [ OK ] CppCPU.Constructor (0 ms) [ RUN ] CppCPU.MemoryMallocFree [ OK ] CppCPU.MemoryMallocFree (0 ms) [ RUN ] CppCPU.Exec [ OK ] CppCPU.Exec (0 ms) [ RUN ] CppCPU.CopyData [ OK ] CppCPU.CopyData (0 ms) [----------] 4 tests from CppCPU (0 ms total) [----------] 8 tests from TestSoftmaxCrossEntropy [ RUN ] TestSoftmaxCrossEntropy.CppForward [ OK ] TestSoftmaxCrossEntropy.CppForward (19 ms) [ RUN ] TestSoftmaxCrossEntropy.CppForwardAryTarget [ OK ] TestSoftmaxCrossEntropy.CppForwardAryTarget (7 ms) [ RUN ] TestSoftmaxCrossEntropy.CppBackward [ OK ] TestSoftmaxCrossEntropy.CppBackward (5 ms) [ RUN ] TestSoftmaxCrossEntropy.CppBackwardAryTarget [ OK ] TestSoftmaxCrossEntropy.CppBackwardAryTarget (4 ms) [ RUN ] TestSoftmaxCrossEntropy.CudaForward [ OK ] TestSoftmaxCrossEntropy.CudaForward (7 ms) [ RUN ] TestSoftmaxCrossEntropy.CudaForwardAryTarget [ OK ] TestSoftmaxCrossEntropy.CudaForwardAryTarget (9 ms) [ RUN ] TestSoftmaxCrossEntropy.CudaBackward [ OK ] TestSoftmaxCrossEntropy.CudaBackward (9 ms) [ RUN ] TestSoftmaxCrossEntropy.CudaBackwardAryTarget [ OK ] TestSoftmaxCrossEntropy.CudaBackwardAryTarget (9 ms) [----------] 8 tests from TestSoftmaxCrossEntropy (70 ms total) [----------] 1 test from CSV [ RUN ] CSV.EncoderDecode [ OK ] CSV.EncoderDecode (0 ms) [----------] 1 test from CSV (0 ms total) [----------] 3 tests from CudnnActivation [ RUN ] CudnnActivation.Setup [ OK ] CudnnActivation.Setup (0 ms) [ RUN ] CudnnActivation.Forward [ OK ] CudnnActivation.Forward (9 ms) [ RUN ] CudnnActivation.Backward [ OK ] CudnnActivation.Backward (9 ms) [----------] 3 tests from CudnnActivation (18 ms total) [----------] 3 tests from CudnnBatchNorm [ RUN ] CudnnBatchNorm.Setup [ OK ] CudnnBatchNorm.Setup (0 ms) [ RUN ] CudnnBatchNorm.Forward [ OK ] CudnnBatchNorm.Forward (8 ms) [ RUN ] CudnnBatchNorm.Backward [ OK ] CudnnBatchNorm.Backward (8 ms) [----------] 3 tests from CudnnBatchNorm (17 ms total) [----------] 3 tests from CudnnConvolution [ RUN ] CudnnConvolution.Setup [ OK ] CudnnConvolution.Setup (0 ms) [ RUN ] CudnnConvolution.Forward [ OK ] CudnnConvolution.Forward (9 ms) [ RUN ] CudnnConvolution.Backward [ OK ] CudnnConvolution.Backward (9 ms) [----------] 3 tests from CudnnConvolution (18 ms total) [----------] 3 tests from CudnnConvolution_AT [ RUN ] CudnnConvolution_AT.Setup [ OK ] CudnnConvolution_AT.Setup (0 ms) [ RUN ] CudnnConvolution_AT.Forward [ OK ] CudnnConvolution_AT.Forward (11 ms) [ RUN ] CudnnConvolution_AT.Backward [ OK ] CudnnConvolution_AT.Backward (9 ms) [----------] 3 tests from CudnnConvolution_AT (20 ms total) [----------] 3 tests from CudnnDropout [ RUN ] CudnnDropout.Setup [ OK ] CudnnDropout.Setup (0 ms) [ RUN ] CudnnDropout.Forward [ OK ] CudnnDropout.Forward (19 ms) [ RUN ] CudnnDropout.Backward [ OK ] CudnnDropout.Backward (19 ms) [----------] 3 tests from CudnnDropout (38 ms total) [----------] 3 tests from CudnnLRN [ RUN ] CudnnLRN.Setup [ OK ] CudnnLRN.Setup (0 ms) [ RUN ] CudnnLRN.Forward [ OK ] CudnnLRN.Forward (8 ms) [ RUN ] CudnnLRN.Backward [ OK ] CudnnLRN.Backward (8 ms) [----------] 3 tests from CudnnLRN (16 ms total) [----------] 3 tests from CudnnPooling [ RUN ] CudnnPooling.Setup [ OK ] CudnnPooling.Setup (0 ms) [ RUN ] CudnnPooling.Forward [ OK ] CudnnPooling.Forward (7 ms) [ RUN ] CudnnPooling.Backward [ OK ] CudnnPooling.Backward (8 ms) [----------] 3 tests from CudnnPooling (15 ms total) [----------] 3 tests from TestCudnnRNN [ RUN ] TestCudnnRNN.Setup [ OK ] TestCudnnRNN.Setup (0 ms) [ RUN ] TestCudnnRNN.Forward [ OK ] TestCudnnRNN.Forward (19 ms) [ RUN ] TestCudnnRNN.Backward [ OK ] TestCudnnRNN.Backward (19 ms) [----------] 3 tests from TestCudnnRNN (38 ms total) [----------] 5 tests from CudnnSoftmax [ RUN ] CudnnSoftmax.Setup [ OK ] CudnnSoftmax.Setup (0 ms) [ RUN ] CudnnSoftmax.Forward1D [ OK ] CudnnSoftmax.Forward1D (8 ms) [ RUN ] CudnnSoftmax.Backward1D [ OK ] CudnnSoftmax.Backward1D (8 ms) [ RUN ] CudnnSoftmax.Forward2D [ OK ] CudnnSoftmax.Forward2D (7 ms) [ RUN ] CudnnSoftmax.Backward2D [ OK ] CudnnSoftmax.Backward2D (8 ms) [----------] 5 tests from CudnnSoftmax (31 ms total) [----------] 5 tests from Dense [ RUN ] Dense.Setup [ OK ] Dense.Setup (0 ms) [ RUN ] Dense.ForwardCpp [ OK ] Dense.ForwardCpp (0 ms) [ RUN ] Dense.BackwardCpp [ OK ] Dense.BackwardCpp (0 ms) [ RUN ] Dense.ForwardCuda [ OK ] Dense.ForwardCuda (8 ms) [ RUN ] Dense.BackwardCuda [ OK ] Dense.BackwardCuda (8 ms) [----------] 5 tests from Dense (16 ms total) [----------] 3 tests from Dropout [ RUN ] Dropout.Setup [ OK ] Dropout.Setup (0 ms) [ RUN ] Dropout.Forward [ OK ] Dropout.Forward (0 ms) [ RUN ] Dropout.Backward [ OK ] Dropout.Backward (0 ms) [----------] 3 tests from Dropout (0 ms total) [----------] 5 tests from Flatten [ RUN ] Flatten.Setup [ OK ] Flatten.Setup (0 ms) [ RUN ] Flatten.ForwardCPU [ OK ] Flatten.ForwardCPU (0 ms) [ RUN ] Flatten.BackwardCPU [ OK ] Flatten.BackwardCPU (0 ms) [ RUN ] Flatten.ForwardGPU [ OK ] Flatten.ForwardGPU (8 ms) [ RUN ] Flatten.BackwardGPU [ OK ] Flatten.BackwardGPU (7 ms) [----------] 5 tests from Flatten (15 ms total) [----------] 5 tests from ImageTransformer [ RUN ] ImageTransformer.Setup [ OK ] ImageTransformer.Setup (0 ms) [ RUN ] ImageTransformer.Apply3D [ OK ] ImageTransformer.Apply3D (0 ms) [ RUN ] ImageTransformer.Apply2D [ OK ] ImageTransformer.Apply2D (0 ms) [ RUN ] ImageTransformer.Crop [ OK ] ImageTransformer.Crop (0 ms) [ RUN ] ImageTransformer.Mirror [ OK ] ImageTransformer.Mirror (0 ms) [----------] 5 tests from ImageTransformer (0 ms total) [----------] 5 tests from Initializer [ RUN ] Initializer.Constant [ OK ] Initializer.Constant (0 ms) [ RUN ] Initializer.Gaussian [ OK ] Initializer.Gaussian (0 ms) [ RUN ] Initializer.ConstantCUDA [ OK ] Initializer.ConstantCUDA (8 ms) [ RUN ] Initializer.GaussianCUDA [ OK ] Initializer.GaussianCUDA (9 ms) [ RUN ] Initializer.XavierCUDA [ OK ] Initializer.XavierCUDA (7 ms) [----------] 5 tests from Initializer (24 ms total) [----------] 2 tests from Layer [ RUN ] Layer.CreateLayer [ OK ] Layer.CreateLayer (0 ms) [ RUN ] Layer.CreateCudnnLayer [ OK ] Layer.CreateCudnnLayer (0 ms) [----------] 2 tests from Layer (0 ms total) [----------] 6 tests from Logging [ RUN ] Logging.InfoLogging [I d0409 t11:43:34 p25776:416 /root/dcsysh/singa/test/singa/test_logging.cc:29] test info logging [ OK ] Logging.InfoLogging (0 ms) [ RUN ] Logging.WarningLogging [W d0409 t11:43:34 p25776:416 /root/dcsysh/singa/test/singa/test_logging.cc:35] test warning logging [ OK ] Logging.WarningLogging (0 ms) [ RUN ] Logging.ErrorLogging [E d0409 t11:43:34 p25776:416 /root/dcsysh/singa/test/singa/test_logging.cc:41] test error logging [ OK ] Logging.ErrorLogging (0 ms) [ RUN ] Logging.FatalLogging [ OK ] Logging.FatalLogging (0 ms) [ RUN ] Logging.SetLogDestination [ OK ] Logging.SetLogDestination (0 ms) [ RUN ] Logging.StderrLoggingLevel [W d0409 t11:43:34 p25776:416 /root/dcsysh/singa/test/singa/test_logging.cc:62] test warning logging to stderr and file [E d0409 t11:43:34 p25776:416 /root/dcsysh/singa/test/singa/test_logging.cc:63] test error logging to stderr and file [ OK ] Logging.StderrLoggingLevel (0 ms) [----------] 6 tests from Logging (0 ms total) [----------] 3 tests from LRN [ RUN ] LRN.Setup [ OK ] LRN.Setup (0 ms) [ RUN ] LRN.Forward [ OK ] LRN.Forward (0 ms) [ RUN ] LRN.Backward [ OK ] LRN.Backward (0 ms) [----------] 3 tests from LRN (0 ms total) [----------] 1 test from MemPool [ RUN ] MemPool.CompareCudaCnmem [ OK ] MemPool.CompareCudaCnmem (1148 ms) [----------] 1 test from MemPool (1148 ms total) [----------] 4 tests from TestMSE [ RUN ] TestMSE.CppForward [ OK ] TestMSE.CppForward (0 ms) [ RUN ] TestMSE.CppBackward [ OK ] TestMSE.CppBackward (0 ms) [ RUN ] TestMSE.CudaForward [ OK ] TestMSE.CudaForward (7 ms) [ RUN ] TestMSE.CudaBackward [ OK ] TestMSE.CudaBackward (8 ms) [----------] 4 tests from TestMSE (15 ms total) [----------] 2 tests from Nesterov [ RUN ] Nesterov.ApplyCPU [ OK ] Nesterov.ApplyCPU (0 ms) [ RUN ] Nesterov.ApplyCUDA [ OK ] Nesterov.ApplyCUDA (7 ms) [----------] 2 tests from Nesterov (7 ms total) [----------] 3 tests from DNNLOperationBatchNorm [ RUN ] DNNLOperationBatchNorm.ForwardInference [ OK ] DNNLOperationBatchNorm.ForwardInference (5 ms) [ RUN ] DNNLOperationBatchNorm.ForwardTraining [ OK ] DNNLOperationBatchNorm.ForwardTraining (14 ms) [ RUN ] DNNLOperationBatchNorm.Backward [ OK ] DNNLOperationBatchNorm.Backward (5 ms) [----------] 3 tests from DNNLOperationBatchNorm (24 ms total) [----------] 3 tests from DNNLOperation_Convolution [ RUN ] DNNLOperation_Convolution.Forward [ OK ] DNNLOperation_Convolution.Forward (6 ms) [ RUN ] DNNLOperation_Convolution.Performance [avg]forward Time difference = 1432[microsec] [avg]backwardx Time difference = 1236[microsec] [avg]backwardW Time difference = 940[microsec] [ OK ] DNNLOperation_Convolution.Performance (387 ms) [ RUN ] DNNLOperation_Convolution.Backward [ OK ] DNNLOperation_Convolution.Backward (0 ms) [----------] 3 tests from DNNLOperation_Convolution (394 ms total) [----------] 4 tests from DNNLOperationPooling [ RUN ] DNNLOperationPooling.Forward [ OK ] DNNLOperationPooling.Forward (1 ms) [ RUN ] DNNLOperationPooling.ForwardAverage [ OK ] DNNLOperationPooling.ForwardAverage (0 ms) [ RUN ] DNNLOperationPooling.Backward [ OK ] DNNLOperationPooling.Backward (0 ms) [ RUN ] DNNLOperationPooling.BackwardAvg [ OK ] DNNLOperationPooling.BackwardAvg (0 ms) [----------] 4 tests from DNNLOperationPooling (3 ms total) [----------] 5 tests from Platform [ RUN ] Platform.CreateMultDevice [ OK ] Platform.CreateMultDevice (1296 ms) [ RUN ] Platform.NumGPUs [ OK ] Platform.NumGPUs (0 ms) [ RUN ] Platform.QueryMem [ OK ] Platform.QueryMem (1 ms) [ RUN ] Platform.CreateDevice [ OK ] Platform.CreateDevice (1 ms) [ RUN ] Platform.CreatTensor [ OK ] Platform.CreatTensor (0 ms) [----------] 5 tests from Platform (1299 ms total) [----------] 3 tests from Pooling [ RUN ] Pooling.Setup [ OK ] Pooling.Setup (0 ms) [ RUN ] Pooling.Forward [ OK ] Pooling.Forward (0 ms) [ RUN ] Pooling.Backward [ OK ] Pooling.Backward (0 ms) [----------] 3 tests from Pooling (0 ms total) [----------] 5 tests from PReLU [ RUN ] PReLU.Setup [ OK ] PReLU.Setup (0 ms) [ RUN ] PReLU.ForwardCPU [ OK ] PReLU.ForwardCPU (0 ms) [ RUN ] PReLU.BackwardCPU [ OK ] PReLU.BackwardCPU (0 ms) [ RUN ] PReLU.ForwardGPU [ OK ] PReLU.ForwardGPU (3 ms) [ RUN ] PReLU.BackwardGPU [ OK ] PReLU.BackwardGPU (9 ms) [----------] 5 tests from PReLU (12 ms total) [----------] 2 tests from RMSProp [ RUN ] RMSProp.ApplyCPU [ OK ] RMSProp.ApplyCPU (0 ms) [ RUN ] RMSProp.ApplyCUDA [ OK ] RMSProp.ApplyCUDA (6 ms) [----------] 2 tests from RMSProp (6 ms total) [----------] 10 tests from TestGraph [ RUN ] TestGraph.AddOp [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.AddOp (6 ms) [ RUN ] TestGraph.AddSyncOp [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.AddSyncOp (6 ms) [ RUN ] TestGraph.AddInplaceOp [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.AddInplaceOp (7 ms) [ RUN ] TestGraph.BlockTypeInput [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.BlockTypeInput (6 ms) [ RUN ] TestGraph.BlockTypeParam [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.BlockTypeParam (6 ms) [ RUN ] TestGraph.BlockTypeInter [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.BlockTypeInter (7 ms) [ RUN ] TestGraph.BlockTypeEnd [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.BlockTypeEnd (6 ms) [ RUN ] TestGraph.RunGraph [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.RunGraph (6 ms) [ RUN ] TestGraph.RunInSerial [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.RunInSerial (7 ms) [ RUN ] TestGraph.AutoRecycle [ ] Test graph on device [cpp_cpu] [ ] Test graph on device [cuda_gpu] [ OK ] TestGraph.AutoRecycle (6 ms) [----------] 10 tests from TestGraph (63 ms total) [----------] 4 tests from SGD [ RUN ] SGD.ApplyWithoutMomentum [ OK ] SGD.ApplyWithoutMomentum (0 ms) [ RUN ] SGD.ApplyWithMomentum [ OK ] SGD.ApplyWithMomentum (0 ms) [ RUN ] SGD.ApplyWithoutMomentumCuda [ OK ] SGD.ApplyWithoutMomentumCuda (6 ms) [ RUN ] SGD.ApplyWithMomentumCuda [ OK ] SGD.ApplyWithMomentumCuda (6 ms) [----------] 4 tests from SGD (12 ms total) [----------] 9 tests from Slice [ RUN ] Slice.Setup [ OK ] Slice.Setup (0 ms) [ RUN ] Slice.ForwardSliceRowCpp [ OK ] Slice.ForwardSliceRowCpp (0 ms) [ RUN ] Slice.ForwardSliceColumn [ OK ] Slice.ForwardSliceColumn (0 ms) [ RUN ] Slice.ForwardSliceRowCuda [ OK ] Slice.ForwardSliceRowCuda (11 ms) [ RUN ] Slice.ForwardSliceColumnCuda [ OK ] Slice.ForwardSliceColumnCuda (12 ms) [ RUN ] Slice.BackwardSliceRowCpp [ OK ] Slice.BackwardSliceRowCpp (0 ms) [ RUN ] Slice.BackwardSliceColumn [ OK ] Slice.BackwardSliceColumn (0 ms) [ RUN ] Slice.BackwardSliceRowCuda [ OK ] Slice.BackwardSliceRowCuda (6 ms) [ RUN ] Slice.BackwardSliceColumnCuda [ OK ] Slice.BackwardSliceColumnCuda (6 ms) [----------] 9 tests from Slice (35 ms total) [----------] 3 tests from Snapshot [ RUN ] Snapshot.WriteTest [ OK ] Snapshot.WriteTest (8 ms) [ RUN ] Snapshot.ReadTest [ OK ] Snapshot.ReadTest (1 ms) [ RUN ] Snapshot.ReadIntTest [ OK ] Snapshot.ReadIntTest (6 ms) [----------] 3 tests from Snapshot (15 ms total) [----------] 3 tests from Softmax [ RUN ] Softmax.Setup [ OK ] Softmax.Setup (0 ms) [ RUN ] Softmax.Forward [ OK ] Softmax.Forward (3 ms) [ RUN ] Softmax.Backward [ OK ] Softmax.Backward (3 ms) [----------] 3 tests from Softmax (7 ms total) [----------] 15 tests from TensorClass [ RUN ] TensorClass.Constructor [ OK ] TensorClass.Constructor (0 ms) [ RUN ] TensorClass.Reshape [ OK ] TensorClass.Reshape (0 ms) [ RUN ] TensorClass.FloatAsTypeIntCuda [ OK ] TensorClass.FloatAsTypeIntCuda (7 ms) [ RUN ] TensorClass.IntAsTypeFloatCuda [ OK ] TensorClass.IntAsTypeFloatCuda (7 ms) [ RUN ] TensorClass.FloatAsTypeFloatCPU [ OK ] TensorClass.FloatAsTypeFloatCPU (0 ms) [ RUN ] TensorClass.FloatAsTypeIntCPU [ OK ] TensorClass.FloatAsTypeIntCPU (0 ms) [ RUN ] TensorClass.IntAsTypeFloatCPU [ OK ] TensorClass.IntAsTypeFloatCPU (0 ms) [ RUN ] TensorClass.ToDevice [ OK ] TensorClass.ToDevice (0 ms) [ RUN ] TensorClass.CopyDataFromHostPtr [ OK ] TensorClass.CopyDataFromHostPtr (0 ms) [ RUN ] TensorClass.CopyData [ OK ] TensorClass.CopyData (0 ms) [ RUN ] TensorClass.Clone [ OK ] TensorClass.Clone (0 ms) [ RUN ] TensorClass.T [ OK ] TensorClass.T (0 ms) [ RUN ] TensorClass.Repeat [ OK ] TensorClass.Repeat (0 ms) [ RUN ] TensorClass.RepeatData [ OK ] TensorClass.RepeatData (0 ms) [ RUN ] TensorClass.Broadcast [ OK ] TensorClass.Broadcast (0 ms) [----------] 15 tests from TensorClass (15 ms total) [----------] 72 tests from TensorMath [ RUN ] TensorMath.AbsCpp [ OK ] TensorMath.AbsCpp (0 ms) [ RUN ] TensorMath.ExpCpp [ OK ] TensorMath.ExpCpp (0 ms) [ RUN ] TensorMath.ExpStrideCpp [ OK ] TensorMath.ExpStrideCpp (0 ms) [ RUN ] TensorMath.LogCpp [ OK ] TensorMath.LogCpp (0 ms) [ RUN ] TensorMath.ReLUCpp [ OK ] TensorMath.ReLUCpp (0 ms) [ RUN ] TensorMath.SigmoidCpp [ OK ] TensorMath.SigmoidCpp (0 ms) [ RUN ] TensorMath.SignCpp [ OK ] TensorMath.SignCpp (0 ms) [ RUN ] TensorMath.SoftPlusCpp [ OK ] TensorMath.SoftPlusCpp (0 ms) [ RUN ] TensorMath.SoftSignCpp [ OK ] TensorMath.SoftSignCpp (0 ms) [ RUN ] TensorMath.SqrtCpp [ OK ] TensorMath.SqrtCpp (0 ms) [ RUN ] TensorMath.SquareCpp [ OK ] TensorMath.SquareCpp (0 ms) [ RUN ] TensorMath.TanhCpp [ OK ] TensorMath.TanhCpp (0 ms) [ RUN ] TensorMath.SumCpp [ OK ] TensorMath.SumCpp (0 ms) [ RUN ] TensorMath.SoftMaxCpp [ OK ] TensorMath.SoftMaxCpp (1 ms) [ RUN ] TensorMath.SoftMaxOnAxisCUDNN [ OK ] TensorMath.SoftMaxOnAxisCUDNN (8 ms) [ RUN ] TensorMath.SoftMaxOnAxisDNNL [ OK ] TensorMath.SoftMaxOnAxisDNNL (15 ms) [ RUN ] TensorMath.LTCpp [ OK ] TensorMath.LTCpp (0 ms) [ RUN ] TensorMath.LECpp [ OK ] TensorMath.LECpp (0 ms) [ RUN ] TensorMath.GTCpp [ OK ] TensorMath.GTCpp (0 ms) [ RUN ] TensorMath.GECpp [ OK ] TensorMath.GECpp (0 ms) [ RUN ] TensorMath.PowCpp [ OK ] TensorMath.PowCpp (0 ms) [ RUN ] TensorMath.SubCpp [ OK ] TensorMath.SubCpp (0 ms) [ RUN ] TensorMath.EltwiseMultCpp [ OK ] TensorMath.EltwiseMultCpp (0 ms) [ RUN ] TensorMath.DivCpp [ OK ] TensorMath.DivCpp (1 ms) [ RUN ] TensorMath.BernoulliCpp [ OK ] TensorMath.BernoulliCpp (0 ms) [ RUN ] TensorMath.UniformCpp [ OK ] TensorMath.UniformCpp (1 ms) [ RUN ] TensorMath.GaussianCpp [ OK ] TensorMath.GaussianCpp (4 ms) [ RUN ] TensorMath.AddTensorCpp [ OK ] TensorMath.AddTensorCpp (0 ms) [ RUN ] TensorMath.AddTensorsCpp [ OK ] TensorMath.AddTensorsCpp (0 ms) [ RUN ] TensorMath.SetValueCpp [ OK ] TensorMath.SetValueCpp (0 ms) [ RUN ] TensorMath.ReshapeCpp [ OK ] TensorMath.ReshapeCpp (0 ms) [ RUN ] TensorMath.TransposeReshapeCpp [ OK ] TensorMath.TransposeReshapeCpp (0 ms) [ RUN ] TensorMath.TransposeFloatCpp [ OK ] TensorMath.TransposeFloatCpp (0 ms) [ RUN ] TensorMath.TransposeIntCpp [ OK ] TensorMath.TransposeIntCpp (0 ms) [ RUN ] TensorMath.BroadcastCpp [ OK ] TensorMath.BroadcastCpp (0 ms) [ RUN ] TensorMath.L2Cpp [ OK ] TensorMath.L2Cpp (0 ms) [ RUN ] TensorMath.MultCpp [ OK ] TensorMath.MultCpp (0 ms) [ RUN ] TensorMath.AddColumnCpp [ OK ] TensorMath.AddColumnCpp (0 ms) [ RUN ] TensorMath.SubColumnCpp [ OK ] TensorMath.SubColumnCpp (0 ms) [ RUN ] TensorMath.DivColumnCpp [ OK ] TensorMath.DivColumnCpp (0 ms) [ RUN ] TensorMath.AddRowCpp [ OK ] TensorMath.AddRowCpp (0 ms) [ RUN ] TensorMath.SubRowCpp [ OK ] TensorMath.SubRowCpp (0 ms) [ RUN ] TensorMath.MultRowCpp [ OK ] TensorMath.MultRowCpp (0 ms) [ RUN ] TensorMath.MultColumnCpp [ OK ] TensorMath.MultColumnCpp (0 ms) [ RUN ] TensorMath.DivRowCpp [ OK ] TensorMath.DivRowCpp (0 ms) [ RUN ] TensorMath.SumRowsCpp [ OK ] TensorMath.SumRowsCpp (0 ms) [ RUN ] TensorMath.SumColumnsCpp [ OK ] TensorMath.SumColumnsCpp (0 ms) [ RUN ] TensorMath.ConcatenateRowsCpp [ OK ] TensorMath.ConcatenateRowsCpp (0 ms) [ RUN ] TensorMath.ConcatenateColumnsCpp [ OK ] TensorMath.ConcatenateColumnsCpp (0 ms) [ RUN ] TensorMath.CopyRowsCpp [ OK ] TensorMath.CopyRowsCpp (0 ms) [ RUN ] TensorMath.CopyColumnsCpp [ OK ] TensorMath.CopyColumnsCpp (0 ms) [ RUN ] TensorMath.L2Cuda [ OK ] TensorMath.L2Cuda (5 ms) [ RUN ] TensorMath.MultCuda [ OK ] TensorMath.MultCuda (6 ms) [ RUN ] TensorMath.AddColumnCuda [ OK ] TensorMath.AddColumnCuda (6 ms) [ RUN ] TensorMath.SubColumnCuda [ OK ] TensorMath.SubColumnCuda (6 ms) [ RUN ] TensorMath.MultColumnCuda [ OK ] TensorMath.MultColumnCuda (5 ms) [ RUN ] TensorMath.DivColumnCuda [ OK ] TensorMath.DivColumnCuda (7 ms) [ RUN ] TensorMath.AddRowCuda [ OK ] TensorMath.AddRowCuda (5 ms) [ RUN ] TensorMath.SubRowCuda [ OK ] TensorMath.SubRowCuda (6 ms) [ RUN ] TensorMath.MultRowCuda [ OK ] TensorMath.MultRowCuda (6 ms) [ RUN ] TensorMath.DivRowCuda [ OK ] TensorMath.DivRowCuda (6 ms) [ RUN ] TensorMath.SumRowsCuda [ OK ] TensorMath.SumRowsCuda (6 ms) [ RUN ] TensorMath.SumColumnCuda [ OK ] TensorMath.SumColumnCuda (5 ms) [ RUN ] TensorMath.ExpStrideCuda [ OK ] TensorMath.ExpStrideCuda (6 ms) [ RUN ] TensorMath.ConcatenateRowsCuda [ OK ] TensorMath.ConcatenateRowsCuda (6 ms) [ RUN ] TensorMath.ConcatenateColumnsCuda [ OK ] TensorMath.ConcatenateColumnsCuda (6 ms) [ RUN ] TensorMath.CopyRowsCuda [ OK ] TensorMath.CopyRowsCuda (5 ms) [ RUN ] TensorMath.CopyColumnsCuda [ OK ] TensorMath.CopyColumnsCuda (6 ms) [ RUN ] TensorMath.RowMaxCuda [ OK ] TensorMath.RowMaxCuda (6 ms) [ RUN ] TensorMath.BroadcastCuda [ OK ] TensorMath.BroadcastCuda (6 ms) [ RUN ] TensorMath.SoftPlusCuda [ OK ] TensorMath.SoftPlusCuda (5 ms) [ RUN ] TensorMath.SoftSignCuda [ OK ] TensorMath.SoftSignCuda (6 ms) [----------] 72 tests from TensorMath (151 ms total) [----------] 2 tests from TextFileWriter [ RUN ] TextFileWriter.Create [ OK ] TextFileWriter.Create (3 ms) [ RUN ] TextFileWriter.Append [ OK ] TextFileWriter.Append (3 ms) [----------] 2 tests from TextFileWriter (6 ms total) [----------] 2 tests from TextFileReader [ RUN ] TextFileReader.Read [ OK ] TextFileReader.Read (0 ms) [ RUN ] TextFileReader.SeekToFirst [ OK ] TextFileReader.SeekToFirst (1 ms) [----------] 2 tests from TextFileReader (1 ms total) [----------] 1 test from TimerTest [ RUN ] TimerTest.TestTick [ OK ] TimerTest.TestTick (10 ms) [----------] 1 test from TimerTest (10 ms total) [----------] Global test environment tear-down [==========] 257 tests from 49 test cases ran. (5973 ms total) [ PASSED ] 257 tests. root@71ac539cda77:~/dcsysh/singa/examples/cnn# python3 train.py cnn mnist Starting Epoch 0: Training loss = 578.907959, training accuracy = 0.796141 Evaluation accuracy = 0.937400, Elapsed Time = 2.669918s Starting Epoch 1: Training loss = 232.124695, training accuracy = 0.922609 Evaluation accuracy = 0.962841, Elapsed Time = 2.680867s Starting Epoch 2: Training loss = 167.437912, training accuracy = 0.944220 Evaluation accuracy = 0.971855, Elapsed Time = 2.717271s Starting Epoch 3: Training loss = 138.634125, training accuracy = 0.953392 Evaluation accuracy = 0.966747, Elapsed Time = 2.703004s Starting Epoch 4: Training loss = 117.458504, training accuracy = 0.961096 Evaluation accuracy = 0.973057, Elapsed Time = 2.664401s Starting Epoch 5: Training loss = 104.992790, training accuracy = 0.965198 Evaluation accuracy = 0.979267, Elapsed Time = 2.664580s Starting Epoch 6: Training loss = 96.263885, training accuracy = 0.967249 Evaluation accuracy = 0.980369, Elapsed Time = 2.666607s Starting Epoch 7: Training loss = 89.073364, training accuracy = 0.970051 Evaluation accuracy = 0.975561, Elapsed Time = 2.695501s Starting Epoch 8: Training loss = 82.311523, training accuracy = 0.972385 Evaluation accuracy = 0.980369, Elapsed Time = 2.651947s Starting Epoch 9: Training loss = 78.408806, training accuracy = 0.974270 Evaluation accuracy = 0.979968, Elapsed Time = 2.637256s root@71ac539cda77:~/dcsysh/singa/examples/cnn# python3 train_multiprocess.py cnn mnist --lr 0.01 Starting Epoch 0: Training loss = 625.124268, training accuracy = 0.777227 Evaluation accuracy = 0.941206, Elapsed Time = 1.769801s Starting Epoch 1: Training loss = 235.566132, training accuracy = 0.920757 Evaluation accuracy = 0.945413, Elapsed Time = 1.553996s Starting Epoch 2: Training loss = 171.600082, training accuracy = 0.942258 Evaluation accuracy = 0.969852, Elapsed Time = 1.533054s Starting Epoch 3: Training loss = 139.339203, training accuracy = 0.953476 Evaluation accuracy = 0.972857, Elapsed Time = 1.533077s Starting Epoch 4: Training loss = 120.622467, training accuracy = 0.959118 Evaluation accuracy = 0.971254, Elapsed Time = 1.535132s Starting Epoch 5: Training loss = 105.304459, training accuracy = 0.964777 Evaluation accuracy = 0.978466, Elapsed Time = 1.533926s Starting Epoch 6: Training loss = 99.502411, training accuracy = 0.966964 Evaluation accuracy = 0.975761, Elapsed Time = 1.533763s Starting Epoch 7: Training loss = 88.000076, training accuracy = 0.969985 Evaluation accuracy = 0.977364, Elapsed Time = 1.536587s Starting Epoch 8: Training loss = 85.234161, training accuracy = 0.971004 Evaluation accuracy = 0.976262, Elapsed Time = 1.536565s Starting Epoch 9: Training loss = 79.724716, training accuracy = 0.973591 Evaluation accuracy = 0.983073, Elapsed Time = 1.537776s root@71ac539cda77:~/dcsysh/singa/examples/cnn# python3 train_multiprocess.py resnet cifar10 --lr 0.01 Starting Epoch 0: Training loss = 1169.126221, training accuracy = 0.457913 Evaluation accuracy = 0.580128, Elapsed Time = 71.133318s Starting Epoch 1: Training loss = 800.335693, training accuracy = 0.636098 Evaluation accuracy = 0.675280, Elapsed Time = 71.827541s Starting Epoch 2: Training loss = 636.221191, training accuracy = 0.711799 Evaluation accuracy = 0.735076, Elapsed Time = 72.619528s Starting Epoch 3: Training loss = 542.384583, training accuracy = 0.756250 Evaluation accuracy = 0.768129, Elapsed Time = 72.472028s Starting Epoch 4: Training loss = 473.055786, training accuracy = 0.789904 Evaluation accuracy = 0.792368, Elapsed Time = 72.936581s Starting Epoch 5: Training loss = 424.287170, training accuracy = 0.811498 Evaluation accuracy = 0.818710, Elapsed Time = 73.540340s Starting Epoch 6: Training loss = 385.483887, training accuracy = 0.828926 Evaluation accuracy = 0.830529, Elapsed Time = 73.234501s Starting Epoch 7: Training loss = 355.444275, training accuracy = 0.841927 Evaluation accuracy = 0.844251, Elapsed Time = 74.106983s Starting Epoch 8: Training loss = 328.466522, training accuracy = 0.852644 Evaluation accuracy = 0.827524, Elapsed Time = 73.583801s Starting Epoch 9: Training loss = 302.767761, training accuracy = 0.866426 Evaluation accuracy = 0.855970, Elapsed Time = 73.569264s ```
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
