How to use the pastas.decorators.set_parameter function in pastas

To help you get started, we’ve selected a few pastas examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github pastas / pastas / pastas / noisemodels.py View on Github external
    @set_parameter
    def set_max(self, name, value):
        """Internal method to set the maximum parameter values.

        Notes
        -----
        The preferred method for parameter setting is through the model.

        """
        if name in self.parameters.index:
            self.parameters.loc[name, 'pmax'] = value
        else:
            print('Warning:', name, 'does not exist')
github pastas / pastas / pastas / stressmodels.py View on Github external
    @set_parameter
    def set_max(self, name, value):
        """Method to set the upper bound of the parameter value.

        Examples
        --------

        >>> ts.set_max('parametername', 200)

        """
        self.parameters.loc[name, 'pmax'] = value
github pastas / pastas / pastas / stressmodels.py View on Github external
    @set_parameter
    def set_pmax(self, name, value):
        """Internal method to set the upper bound of the parameter value.

        Notes
        -----
        The preferred method for parameter setting is through the model.

        """
        self.parameters.loc[name, 'pmax'] = value
github pastas / pastas / pastas / noisemodels.py View on Github external
    @set_parameter
    def set_vary(self, name, value):
        """Internal method to set if the parameter is varied during
        optimization.

        Notes
        -----
        The preferred method for parameter setting is through the model.

        """
        self.parameters.loc[name, 'vary'] = value
github pastas / pastas / pastas / stressmodels.py View on Github external
    @set_parameter
    def set_pmin(self, name, value):
        """Internal method to set the lower bound of the parameter value.

        Notes
        -----
        The preferred method for parameter setting is through the model.

        """
        self.parameters.loc[name, 'pmin'] = value
github pastas / pastas / pastas / noisemodels.py View on Github external
    @set_parameter
    def set_initial(self, name, value):
        """Internal method to set the initial parameter value

        Notes
        -----
        The preferred method for parameter setting is through the model.

        """
        if name in self.parameters.index:
            self.parameters.loc[name, 'initial'] = value
        else:
            print('Warning:', name, 'does not exist')
github pastas / pastas / pastas / stressmodels.py View on Github external
    @set_parameter
    def set_initial(self, name, value):
        """Method to set the initial parameter value.

        Examples
        --------

        >>> ts.set_initial('parametername', 200)

        """
        self.parameters.loc[name, 'initial'] = value
github pastas / pastas / pastas / stressmodels.py View on Github external
    @set_parameter
    def set_min(self, name, value):
        """Method to set the lower bound of the parameter value.

        Examples
        --------

        >>> ts.set_min('parametername', 0)

        """
        self.parameters.loc[name, 'pmin'] = value
github pastas / pastas / pastas / stressmodels.py View on Github external
    @set_parameter
    def set_vary(self, name, value):
        """Internal method to set if the parameter is varied during
        optimization.

        Notes
        -----
        The preferred method for parameter setting is through the model.

        """
        self.parameters.loc[name, 'vary'] = bool(value)
github pastas / pastas / pastas / stressmodels.py View on Github external
    @set_parameter
    def set_vary(self, name, value):
        """Method to set if the parameter is varied during optimization.

        Examples
        --------

        >>> ts.set_initial('parametername', 200)

        """
        self.parameters.loc[name, 'vary'] = value