class_docstr: Test class for ablation tests.
class_docstr_tok: ["Test","class","for","ablation","tests","."]
docstr: Test ablation all-combos + cross-validation + feature hashing + samplers.
docstr_tok: ["Test","ablation","all-combos","+","cross-validation","+","feature","hashing","+","samplers","."]
code: def test_ablation_cv_feature_hasher_all_combos_sampler(self):
      """Test ablation all-combos + cross-validation + feature hashing + samplers."""
      config_template_path = (
          config_dir
          / "test_ablation_feature_hasher_sampler_all_combos.template.cfg"
      )
      config_path = fill_in_config_paths(config_template_path)
  
      run_configuration(
          config_path, quiet=True, ablation=None, local=True
      )
  
      # read in the summary file and make sure it has
      # 10 ablated featuresets * (10 folds + 1 average line) * 2 learners = 220
      # lines
      with open(
          output_dir
          / "ablation_cv_feature_hasher_sampler_all_combos_summary.tsv"
      ) as f:
          reader = csv.DictReader(f, dialect=csv.excel_tab)
          num_rows = self.check_ablation_rows(reader)
          self.assertEqual(num_rows, 220)
  
      # make sure there are 10 ablated featuresets * 2 learners = 20 results
      # files
      num_result_files = len(
          list(
              output_dir.glob(
                  "ablation_cv_feature_hasher_sampler_all_combos*.results"
              )
          )
      )
      self.assertEqual(num_result_files, 20)
  
file_path: skll/tests/test_ablation.py
imports: import csv
  import json
  import unittest
  from skll.experiments import run_configuration
  from skll.utils.testing import config_dir, create_jsonlines_feature_files, fill_in_config_paths, output_dir, remove_jsonlines_feature_files, test_dir, train_dir, unlink
label_desc: Use image node_id 11 for calling the TestAblation obj's underlying member method code with example usage: obj.test_ablation_cv_feature_hasher_all_combos_sampler() without return types