class_docstr: :class:`~opacus.optimizers.optimizer.DPOptimizer` that implements
  adaptive clipping strategy
  https://arxiv.org/pdf/1905.03871.pdf
class_docstr_tok: [":","class",":","`","~opacus.optimizers.optimizer.DPOptimizer","`","that","implements","adaptive","clipping","strategy","https",":","\/\/arxiv.org\/pdf\/1905.03871.pdf"]
code: def pre_step(
      self, closure: Optional[Callable[[], float]] = None
  ) -> Optional[float]:
      pre_step_full = super().pre_step()
      if pre_step_full:
          self.update_max_grad_norm()
      return pre_step_full
  
file_path: opacus/opacus/optimizers/adaclipoptimizer.py
imports: from __future__ import annotations
  import logging
  from typing import Callable, Optional
  import torch
  from opt_einsum import contract
  from torch.optim import Optimizer
  from .optimizer import DPOptimizer, _check_processed_flag, _generate_noise, _mark_as_processed
label_desc: Use image node_id 6 for calling the AdaClipDPOptimizer obj's underlying member method code with example usage: obj.pre_step(closure) and returns: pre_step_full