class_docstr: This helper class wraps the DatasetTemplates class
  - Initialized the DatasetTemplates for all existing template folder
  - Give access to each DatasetTemplates
  - Provides aggregated counts over all DatasetTemplates
class_docstr_tok: ["This","helper","class","wraps","the","DatasetTemplates","class","-","Initialized","the","DatasetTemplates","for","all","existing","template","folder","-","Give","access","to","each","DatasetTemplates","-","Provides","aggregated","counts","over","all","DatasetTemplates"]
docstr: Return the overall number count over all datasets
  
  NB: we don't breakdown datasets into subsets for the count, i.e subsets count are included
  into the dataset count
docstr_tok: ["Return","the","overall","number","count","over","all","datasets","NB",":","we","do","n't","breakdown","datasets","into","subsets","for","the","count",",","i.e","subsets","count","are","included","into","the","dataset","count"]
code: def get_templates_count(self) -> Dict:
      """
      Return the overall number count over all datasets
  
      NB: we don't breakdown datasets into subsets for the count, i.e subsets count are included
      into the dataset count
      """
  
      count_dict = defaultdict(int)
      for k, v in self.datasets_templates.items():
          # Subsets count towards dataset count
          count_dict[k[0]] += len(v)
      # converting to regular dict
      return dict(count_dict)
  
imports: import logging
  import os
  import random
  import re
  import uuid
  from collections import Counter, defaultdict
  from shutil import rmtree
  from typing import Dict, List, Optional, Tuple
  import pandas
  import pkg_resources
  import yaml
  from jinja2 import BaseLoader, Environment, meta
  from ..constants import AUTOMM
label_desc: Use image node_id 8 for calling the TemplateCollection obj's underlying member method code with example usage: obj.get_templates_count() and returns: dict