docstr: Predict raw anomaly score of X using the fitted detector.
  
  The anomaly score of an input sample is computed based on different
  detector algorithms. For consistency, outliers are assigned with
  larger anomaly scores.
  
  Parameters
  ----------
  X : numpy array of shape (n_samples, n_features)
      The training input samples. Sparse matrices are accepted only
      if they are supported by the base estimator.
  
  Returns
  -------
  anomaly_scores : numpy array of shape (n_samples,)
      The anomaly score of the input samples.
docstr_tok: ["Predict","raw","anomaly","score","of","X","using","the","fitted","detector",".","The","anomaly","score","of","an","input","sample","is","computed","based","on","different","detector","algorithms",".","For","consistency",",","outliers","are","assigned","with","larger","anomaly","scores",".","Parameters","--","--","--","--","--","X",":","numpy","array","of","shape","(","n_samples",",","n_features",")","The","training","input","samples",".","Sparse","matrices","are","accepted","only","if","they","are","supported","by","the","base","estimator",".","Returns","--","--","--","-","anomaly_scores",":","numpy","array","of","shape","(","n_samples",",",")","The","anomaly","score","of","the","input","samples","."]
code: def decision_function(self, X):
      """Predict raw anomaly score of X using the fitted detector.
  
      The anomaly score of an input sample is computed based on different
      detector algorithms. For consistency, outliers are assigned with
      larger anomaly scores.
  
      Parameters
      ----------
      X : numpy array of shape (n_samples, n_features)
          The training input samples. Sparse matrices are accepted only
          if they are supported by the base estimator.
  
      Returns
      -------
      anomaly_scores : numpy array of shape (n_samples,)
          The anomaly score of the input samples.
      """
      self.model.eval()
  
      dataset = PyODDataset(X=X, mean=self.mean, std=self.std)
      dataloader = torch.utils.data.DataLoader(
          dataset, batch_size=self.batch_size, shuffle=False
      )
  
      X_reconst = np.zeros(
          [
              X.shape[0],
          ]
      )
      with torch.no_grad():
          for data, data_idx in train_loader:
              # print(epoch, data.shape)
              data_cuda = data.to(self.device).float()
              # idx = batch[1]
              # this is the outlier score
              X_reconst[data_idx] = pairwise_distances_no_broadcast(
                  data, self.model(data_cuda).cpu().numpy()
              )
  
      return X_reconst
  
imports: from __future__ import division
  from __future__ import print_function
  import torch
  import numpy
  from sklearn.preprocessing import StandardScaler
  from sklearn.utils import check_array
  from sklearn.utils.validation import check_is_fitted
  from pyod.utils.utility import check_parameter
  from pyod.utils.stat_models import pairwise_distances_no_broadcast
  from pyod.models.base import BaseDetector
  from pyod.utils.data import generate_data
  from pyod.utils.stat_models import pairwise_distances_no_broadcast
  from torch import nn
  from torchvision import transforms
label_desc: Use image node_id 4 for calling the AutoEncoder obj's underlying member method code with example usage: obj.decision_function(X) and returns: X_reconst