class_docstr: Interface implemented by custom data parallel wrappers.
class_docstr_tok: ["Interface","implemented","by","custom","data","parallel","wrappers","."]
code: def wrap(
      self,
      dmp: "DistributedModelParallel",
      env: ShardingEnv,
      device: torch.device,
  ) -> None:
      pass
  
imports: import abc
  import copy
  from collections import OrderedDict
  from typing import Any, cast, Dict, Iterator, List, Optional, Set, Tuple, Type
  import torch
  import torch.distributed
  from torch import nn
  from torch.distributed.algorithms.ddp_comm_hooks import default_hooks
  from torch.distributed.fsdp import FullyShardedDataParallel
  from torch.nn.modules.module import _IncompatibleKeys
  from torch.nn.parallel import DistributedDataParallel
  from torchrec.distributed.comm import get_local_size
  from torchrec.distributed.planner import EmbeddingShardingPlanner, Topology
  from torchrec.distributed.sharding_plan import get_default_sharders
  from torchrec.distributed.types import ModuleSharder, ShardedModule, ShardingEnv, ShardingPlan
  from torchrec.distributed.utils import add_prefix_to_state_dict, append_prefix, copy_to_device, filter_state_dict, sharded_model_copy
  from torchrec.optim.fused import FusedOptimizerModule
  from torchrec.optim.keyed import CombinedOptimizer, KeyedOptimizer
label_desc: Use image node_id 1 for calling the DataParallelWrapper obj's underlying member method code with example usage: obj.wrap(dmp, env, device) without return types