code: def _run_test(self, sf, expected_number_of_features):
      sf["target"] = [
          0 if random.random() < 0.5 else 1
          for i in range(sf.num_rows())
      ]
  
      for model in [
          tc.regression.boosted_trees_regression,
          tc.classifier.boosted_trees_classifier,
      ]:
          m = model.create(
              sf,
              "target",
              validation_set=None,
              max_iterations=5,
              max_depth=2,
          )
  
          out = m.extract_features(sf)
          self.assertEqual(len(out), len(sf))
  
          out = m._extract_features_with_missing(sf)
          self.assertEqual(len(out), len(sf))
  
      for model in [
          tc.regression.random_forest_regression,
          tc.classifier.random_forest_classifier,
          tc.regression.decision_tree_regression,
          tc.classifier.decision_tree_classifier,
      ]:
          m = model.create(
              sf, "target", validation_set=None, max_depth=2
          )
  
          out = m.extract_features(sf)
          self.assertEqual(len(out), len(sf))
  
          out = m._extract_features_with_missing(sf)
          self.assertEqual(len(out), len(sf))
  
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import absolute_import
  import unittest
  import turicreate
  import math
  import uuid
  import random
  import copy
  from turicreate.toolkits import evaluation
  from turicreate.toolkits._main import ToolkitError
  import shutil
  import numpy
  from array import array
label_desc: Use image node_id 1 for calling the TreeExtractFeaturesTest obj's underlying member method code with example usage: obj._run_test(sf, expected_number_of_features) without return types