class_docstr: This class tests the crypten.nn package.
class_docstr_tok: ["This","class","tests","the","crypten.nn","package","."]
docstr: Tests that a warning is thrown that indicates that the `inplace` kwarg
  is ignored when a function is called with `inplace=True`
code: def test_inplace_warning(self):
      """Tests that a warning is thrown that indicates that the `inplace` kwarg
      is ignored when a function is called with `inplace=True`
      """
      modules = [
          "Dropout",
          "DropoutNd",
          "Dropout2d",
          "Dropout3d",
          "Hardtanh",
          "ReLU",
          "ReLU6",
      ]
      for module in modules:
          module_str = (
              module
              if module not in ["Dropout2d", "Dropout3d"]
              else "DropoutNd"
          )
          warning_str = f"CrypTen {module_str} module does not support inplace computation."
          with self.assertLogs(
              logger=logging.getLogger(), level="WARNING"
          ) as cm:
              getattr(crypten.nn, module)(inplace=True)
          self.assertTrue(f"WARNING:root:{warning_str}" in cm.output)
  
imports: import copy
  import itertools
  import logging
  import unittest
  import crypten
  import crypten.communicator
  import torch
  import torch.nn.functional
  from crypten.common.rng import generate_random_ring_element
  from crypten.common.tensor_types import is_float_tensor
  from crypten.config import cfg
  from crypten.encoder import FixedPointEncoder
  from test.multiprocess_test_case import get_random_linear, get_random_test_tensor, MultiProcessTestCase, onehot
label_desc: Use image node_id 13 for calling the TestNN obj's underlying member method code with example usage: obj.test_inplace_warning() without return types