code: def __init__(
      self,
      linear_feature_columns,
      dnn_feature_columns,
      use_fm=True,
      dnn_hidden_units=(1024, 512, 128),
      l2_reg_linear=0.00001,
      l2_reg_embedding=0.00001,
      l2_reg_dnn=0,
      init_std=0.0001,
      seed=1024,
      dnn_dropout=0,
      dnn_activation="relu",
      dnn_use_bn=False,
      task="binary",
      device="cpu",
      gpus=None,
  ):
      super(DeepFM, self).__init__(
          linear_feature_columns,
          dnn_feature_columns,
          l2_reg_linear=l2_reg_linear,
          l2_reg_embedding=l2_reg_embedding,
          init_std=init_std,
          seed=seed,
          task=task,
          device=device,
          gpus=gpus,
      )
  
      self.use_fm = use_fm
      self.use_dnn = (
          len(dnn_feature_columns) > 0 and len(dnn_hidden_units) > 0
      )
      if use_fm:
          self.fm = FM()
  
      if self.use_dnn:
          self.dnn = DNN(
              self.compute_input_dim(dnn_feature_columns),
              dnn_hidden_units,
              activation=dnn_activation,
              l2_reg=l2_reg_dnn,
              dropout_rate=dnn_dropout,
              use_bn=dnn_use_bn,
              init_std=init_std,
              device=device,
          )
          self.dnn_linear = nn.Linear(
              dnn_hidden_units[-1], 1, bias=False
          ).to(device)
  
          self.add_regularization_weight(
              filter(
                  lambda x: "weight" in x[0] and "bn" not in x[0],
                  self.dnn.named_parameters(),
              ),
              l2=l2_reg_dnn,
          )
          self.add_regularization_weight(
              self.dnn_linear.weight, l2=l2_reg_dnn
          )
      self.to(device)
  
imports: from deepctr_torch.models.deepfm import *
  from deepctr_torch.models.basemodel import BaseModel
label_desc: Use image node_id 1 to create a new DeepFM object from inherited base classes: BaseModel with example: obj = DeepFM(linear_feature_columns, dnn_feature_columns, use_fm, dnn_hidden_units, l2_reg_linear, l2_reg_embedding, l2_reg_dnn, init_std, seed, dnn_dropout, dnn_activation, dnn_use_bn, task, device, gpus)