flownet.parameters._relative_permeability module
- class flownet.parameters._relative_permeability.RelativePermeability(distribution_values: pandas.core.frame.DataFrame, ti2ci: pandas.core.frame.DataFrame, satnum: pandas.core.frame.DataFrame, config: <property object at 0x7f15b0f78830>, interpolation_values: typing.Optional[pandas.core.frame.DataFrame] = None)
Bases:
flownet.parameters._base_parameter.Parameter
Parameter type which takes care of stochastically drawn Relative Permeability parameters.
Required parameters for SWOF generation: “swirr”, “swl”, “swcr”, “sorw”, “nw”, “now”, “krwend”, “kroend” Required parameters for SGOF generation: “swirr”, “swl”, “sgcr”, “sorg”, “ng”, “nog”, “krgend”, “kroend”
- Parameters
distribution_values –
A dataframe with eight columns (“parameter”, “minimum”, “maximum”, “mean”, “base”, “stddev”, “distribution”, “satnum”) which state:
The name of the parameter,
The minimum value of the parameter (set to None if not applicable),
The maximum value of the parameter (set to None if not applicable),
The mean value of the parameter,
The mode of the parameter distribution (set to None if not applicable),
The standard deviation of the parameter,
The type of probability distribution,
To which SATNUM this applies.
ti2ci – A dataframe with index equal to tube model index, and one column which equals cell indices.
satnum – A dataframe defining the SATNUM for each flow tube.
config – Information from the FlowNet config yaml
interpolation_values – A dataframe with information about the relative permeability models used for interpolation. One row corresponds to one model, the column names should be the names of the parameters needed to establish the model. In addition there should be a column “CASE”, which should be set to “low”, “base” or “high”, and a column “SATNUM” defining which SATNUM region the model applies to.
- _abc_impl = <_abc_data object>
- _check_krwmax(params: Dict) Dict
Helper function to check if krwmax is defined in config file or if it should be defaulted to 1.
- Parameters
params – Dictionary with parameter names and parameter values for one realization in ERT
- Returns
Updated dictionary with parameters
- _check_parameters() Tuple[bool, bool]
Helper function to check the user-defined parameters and determination of what to generate: SWOF/SGOF. It will raise an error if something is wrong.
- Returns
A tuple of booleans defining whether to generate the SWOF and or SGOF tables.
- get_dims() Union[None, Dict[str, int]]
Function to export the table dimensions used for memory allocation in Flow.
- Returns
Dictionary containing all dimensions to set.
- render_output() Dict
Creates SWOF/SGOF and SATNUM include content - which are given to the PROPS and GRID section.
- Returns
SWOF/SGOF and SATNUM include content
- flownet.parameters._relative_permeability.interpolate_go(parameter: float, scalrec: Dict) Dict
Creates interpolated saturation endpoints and relative permeability endpoints for gas/oil based on an interpolation parameter and three separate input cases (low/base/high).
- Parameters
parameter – A value on the interval -1 to 1 used for interpolation
scalrec – A dataframe containing the relative permeability and saturation endpoints for the low/base/high cases
- Returns
A dictionary with the interpolated gas/oil saturation and relative permeability endpoints
- flownet.parameters._relative_permeability.interpolate_wo(parameter: float, scalrec: Dict) Dict
Creates interpolated saturation endpoints and relative permeability endpoints for water/oil based on an interpolation parameter and three separate input cases (low/base/high).
- Parameters
parameter – A value on the interval -1 to 1 used for interpolation
scalrec – A dictionary containing the relative permeability and saturation endpoints for the low/base/high cases
- Returns
A dictionary with the interpolated water/oil saturation and relative permeability endpoints
- flownet.parameters._relative_permeability.sgof_from_parameters(parameters: Dict) str
Creates a SGOF table based on a dictionary of input parameters/values
- Parameters
parameters – Dictionary of saturation and relative permeability endpoints
- Returns
A string with the resulting SGOF table
- flownet.parameters._relative_permeability.swof_from_parameters(parameters: Dict) str
Creates a SWOF table based on a dictionary of input parameters/values
- Parameters
parameters – Dictionary of saturation and relative permeability endpoints
- Returns
A string with the resulting SWOF table