strip_dict

strip_dict#

stimupy.utils.strip_dict(dct, func)#

Create a dictionary by stripping it from all keys that are not also an argument to the provided function

Parameters:
  • dct (dict) – dict which will be stripped

  • func (function) – Get argument names from this function

Returns:

same as input dict but stripped from all keys which are not also an argument to the provided function

Return type:

dict[str, Any]