Browse Source

fix anomaly detection docs

tags/v1.2.0-rc1
zhangxinfeng3 5 years ago
parent
commit
f1e1dcbb45
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      mindspore/nn/probability/toolbox/anomaly_detection.py

+ 1
- 1
mindspore/nn/probability/toolbox/anomaly_detection.py View File

@@ -69,7 +69,7 @@ class VAEAnomalyDetection:
sample_x (Tensor): The sample to be predicted, the shape is (N, C, H, W). sample_x (Tensor): The sample to be predicted, the shape is (N, C, H, W).


Returns: Returns:
numpy.dtype, the predicted outlier score of the sample.
float, the predicted outlier score of the sample.
""" """
reconstructed_sample = self.vae.reconstruct_sample(sample_x) reconstructed_sample = self.vae.reconstruct_sample(sample_x)
return self._calculate_euclidean_distance(sample_x.asnumpy(), reconstructed_sample.asnumpy()) return self._calculate_euclidean_distance(sample_x.asnumpy(), reconstructed_sample.asnumpy())


Loading…
Cancel
Save