utils¶
This module contains utility functions, mainly used for internal purposes.
Cache¶
_cache (network, func, params, result_keys[, ...]) |
Save result of func(**params) into network dicts using result_keys. |
Checks¶
check_if_positive (parameters, parameter_names) |
Check that will raise an error if parameters are negative. |
check_for_valid_k_in_fast_synaptic_regime (...) |
Check whether tau_m and tau_s imply fast synaptic regime. |
_check_positive_params (func) |
Decorator that checks that a fixed list of parameters is positive. |
_check_k_in_fast_synaptic_regime (func) |
Decorator checking whether func is operating in fast synaptic regime. |
Miscellaneous¶
build_full_arg_list (signature, args, kwargs) |
Creates a full list of arguments including standard arguments. |
get_list_of_required_parameters (func) |
Returns list of arguments required by func. |
get_list_of_optional_parameters (func) |
Returns list of optional arguments of func. |
get_required_network_params (network, func[, ...]) |
Extracts dict with required args for func from network.network_params. |
get_optional_network_params (network, func) |
Extracts dict with optional args for func from network.network_params. |
get_required_results (network, keys, results_keys) |
Extracts dict with results from network.results. |