title: DeepFM Features
body: <p>I'm trying to train a binary classification model using DeepFM for the first time.  The dataset consists of anonymized ids mapped to a list of segments with a boolean 1 or 0 if they have the segment.</p>
  <p>The data is one hot encoded so data looks like:</p>
  <div class="s-table-container">
  <table class="s-table">
  <thead>
  <tr>
  <th>id</th>
  <th>SEGMENT1</th>
  <th>SEGMENT2</th>
  <th>SEGMENT3</th>
  <th>Label</th>
  </tr>
  </thead>
  <tbody>
  <tr>
  <td>id1</td>
  <td>0</td>
  <td>1</td>
  <td>0</td>
  <td>0</td>
  </tr>
  <tr>
  <td>id2</td>
  <td>1</td>
  <td>1</td>
  <td>1</td>
  <td>1</td>
  </tr>
  <tr>
  <td>id2</td>
  <td>1</td>
  <td>0</td>
  <td>1</td>
  <td>1</td>
  </tr>
  </tbody>
  </table>
  </div>
  <p>I am training via the documentation in deepctr documents, but they have a requirement for dense (numeric) and sparse features (categorical).  I would assume I dense since its defined by 0 and 1 and I don't need to transform anything with label-encoder for categorical.  Do I still need to use dnn_feature_columns and linear_feature_columns?  I don't have both in my data.</p>
  <pre><code>linear_feature_columns = fixlen_feature_columns
  
  feature_names = get_feature_names(linear_feature_columns + dnn_feature_columns)
  
  </code></pre>
  <pre><code>train_model_input = {name: train[name] for name in feature_names}
  test_model_input = {name: test[name] for name in feature_names}
  
  model = DeepFM(linear_feature_columns, dnn_feature_columns, task='binary')
  model.compile(&quot;adam&quot;, &quot;binary_crossentropy&quot;,
                    metrics=['binary_crossentropy'], )
  </code></pre>
  <p>Thank you in advance!</p>