# Path: ndd/exceptions.py
# class EstimatorParameterError(NddError):
#     """Getting/setting invalid estimator parameters."""


    from inspect import signature
    from ndd.funcsigs import signature
from collections import defaultdict
from ndd.exceptions import EstimatorParameterError  # pylint: disable=C0412
import logging
import numpy
                deep_items = value.get_params().items()
                out.update((key + '__' + k, val) for k, val in deep_items)
            out[key] = value
        return out

    def set_params(self, **params):
        """Set the parameters of this estimator.
        The method works on simple estimators as well as on nested objects
        (such as pipelines). The latter have parameters of the form
        ``<component>__<parameter>`` so that it's possible to update each
        component of a nested object.

        Returns
        -------
        self

        Raises
        ------
        EstimatorParameterError
            When setting an invalid parameter
        """
        if not params:
            # Simple optimization to gain speed (inspect is slow)
            return self
        valid_params = self.get_params(deep=True)

        nested_params = defaultdict(dict)  # grouped by prefix
        for key, value in params.items():
            key, delim, sub_key = key.partition('__')
            if key not in valid_params:

# Path: ndd/exceptions.py
# class EstimatorParameterError(NddError):
#     """Getting/setting invalid estimator parameters."""


# Path: ndd/base.py
    from inspect import signature
    from ndd.funcsigs import signature
from collections import defaultdict
from ndd.exceptions import EstimatorParameterError  # pylint: disable=C0412
import logging
import numpy

                deep_items = value.get_params().items()
                out.update((key + '__' + k, val) for k, val in deep_items)
            out[key] = value
        return out

    def set_params(self, **params):
        """Set the parameters of this estimator.
        The method works on simple estimators as well as on nested objects
        (such as pipelines). The latter have parameters of the form
        ``<component>__<parameter>`` so that it's possible to update each
        component of a nested object.

        Returns
        -------
        self

        Raises
        ------
        EstimatorParameterError
            When setting an invalid parameter
        """
        if not params:
            # Simple optimization to gain speed (inspect is slow)
            return self
        valid_params = self.get_params(deep=True)

        nested_params = defaultdict(dict)  # grouped by prefix
        for key, value in params.items():
            key, delim, sub_key = key.partition('__')
            if key not in valid_params:

                raise EstimatorParameterError(