class_docstr: A data structure that provides an interface to access nested dictionaries with "flattened keys", and a few more functions.
  
  e.g.
      dct = RecursiveDict({'a':{'b':2}})
      assert dct["a__b"] == 2
      dct["a__b__c"] = 3
      assert dct['a']['b']['c'] == dct["a__b__c"] == dct.to_flat_dict()["a__b__c"]
  
  This class serves as a base for HyperparameterSamples and HyperparameterSpace
class_docstr_tok: ["A","data","structure","that","provides","an","interface","to","access","nested","dictionaries","with","``","flattened","keys","''",",","and","a","few","more","functions",".","e.g",".","dct","=","RecursiveDict","(","{","'","a","'",":","{","'","b':2","}","}",")","assert","dct","[","``","a__b","''","]","==","2","dct","[","``","a__b__c","''","]","=","3","assert","dct","[","'","a","'","]","[","'","b","'","]","[","'","c","'","]","==","dct","[","``","a__b__c","''","]","==","dct.to_flat_dict","(",")","[","``","a__b__c","''","]","This","class","serves","as","a","base","for","HyperparameterSamples","and","HyperparameterSpace"]
docstr: Returns a FlatDict, that is a totally flatened OrderedDict[str, HPSampledValue],
  with no recursively nested elements, i.e.: {fully__flattened__params: value}.
  
  .. info::
      The returned FlatDict is sorted in a new alphabetical order.
  
  :param use_wildcards: If True, wildcards are used in the keys, as if calling self.to_wildcards() directly. See :func:`to_wildcards` for more info.
docstr_tok: ["Returns","a","FlatDict",",","that","is","a","totally","flatened","OrderedDict","[","str",",","HPSampledValue","]",",","with","no","recursively","nested","elements",",","i.e",".",":","{","fully__flattened__params",":","value","}",".","..","info",":",":","The","returned","FlatDict","is","sorted","in","a","new","alphabetical","order",".",":","param","use_wildcards",":","If","True",",","wildcards","are","used","in","the","keys",",","as","if","calling","self.to_wildcards","(",")","directly",".","See",":","func",":","`","to_wildcards","`","for","more","info","."]
code: def to_flat_dict(self, use_wildcards=False) -> FlatDict:
      """
      Returns a FlatDict, that is a totally flatened OrderedDict[str, HPSampledValue],
      with no recursively nested elements, i.e.: {fully__flattened__params: value}.
  
      .. info::
          The returned FlatDict is sorted in a new alphabetical order.
  
      :param use_wildcards: If True, wildcards are used in the keys, as if calling self.to_wildcards() directly. See :func:`to_wildcards` for more info.
      """
      if use_wildcards is True:
          return self.to_wildcards()
      return OrderedDict(self.iter_flat())
  
imports: import typing
  from collections import Counter, OrderedDict, defaultdict
  from copy import copy
  from typing import Any, Dict, Iterable, List, Set, Union
  from neuraxle.hyperparams.distributions import FixedHyperparameter, HPSampledValue, HyperparameterDistribution
  from neuraxle.hyperparams.scipy_distributions import ScipyContinuousDistributionWrapper, ScipyDiscreteDistributionWrapper
  from scipy.stats import rv_continuous, rv_discrete
  from scipy.stats._distn_infrastructure import rv_generic
label_desc: Use image node_id 13 for calling the RecursiveDict obj's underlying member method code with example usage: obj.to_flat_dict(use_wildcards) and returns: OrderedDict, self