class_docstr: Frechet Inception Distance.
  
  This is a minimalist torchmetrics wrapper for the FID calculation in
  torch-fidelity. Unlike the torchmetrics implementation, intermediate
  features are stored on CPU prior to final metric calculation.
  
  Args:
      feature: An integer that indicates the inceptionv3 feature layer to
          choose. Can be one of the following: 64, 192, 768, 2048.
      kwargs: Additional keyword arguments, see :ref:`Metric kwargs` for more
          info.
class_docstr_tok: ["Frechet","Inception","Distance",".","This","is","a","minimalist","torchmetrics","wrapper","for","the","FID","calculation","in","torch-fidelity",".","Unlike","the","torchmetrics","implementation",",","intermediate","features","are","stored","on","CPU","prior","to","final","metric","calculation",".","Args",":","feature",":","An","integer","that","indicates","the","inceptionv3","feature","layer","to","choose",".","Can","be","one","of","the","following",":","64",",","192",",","768",",","2048.","kwargs",":","Additional","keyword","arguments",",","see",":","ref",":","`","Metric","kwargs","`","for","more","info","."]
code: def update(self, imgs: Tensor, real: bool) -> None:  # type: ignore
      imgs = (imgs * 255).byte() if self.normalize else imgs
      features = self.inception(imgs)
  
      if features.dim() == 1:
          features = features.unsqueeze(0)
      if real:
          self.real_features.append(features.cpu())
      else:
          self.fake_features.append(features.cpu())
  
file_path: NeuralCompression/neuralcompression/metrics/_fid.py
imports: from typing import Any, List
  import torch
  from torch import Tensor
  from torch.nn import Module
  from torch_fidelity.metric_fid import fid_features_to_statistics, fid_statistics_to_metric
  from torchmetrics.image.fid import NoTrainInceptionV3
  from torchmetrics.metric import Metric
label_desc: Use image node_id 2 for calling the FrechetInceptionDistance obj's underlying member method code with example usage: obj.update(imgs, real) without return types