flownet.network_model._create_egrid module

flownet.network_model._create_egrid.construct_kw(name: str, values: List[Union[float, int]], int_type: bool = False) ecl.eclfile.ecl_kw.EclKW

This function generates a Flow-type keyword for a given set of values.

Parameters
  • name – Name for the EclKW to be generated

  • values – List of values to transform to an EclKW

  • int_type – Use integer (True) or floating point (False) values

Returns

EclKW instance

flownet.network_model._create_egrid.create_egrid(df_coord: pandas.core.frame.DataFrame, filename: pathlib.Path)
This function does the following:
  • Takes as input a dataframe with coordinates defining all the grid cells

  • Store it as a Flow .EGRID file called filename

The mandatory dataframe columns are xi, yi, zi (where i is the integers 0-7). An optional column name is ACTNUM.

A grid cell is defined by 8 corner points (4 in the bottom plane, 4 in the top plane). The ordering is following the Flow definition):

2—3 6—7 | | | | 0—1 4—5

j

/| |


o———-> i

The grid cells are assumed to correspond to one or more one dimensional flow models. Between two one dimensional models there should always be one inactive cell. Grid cells can be set to be inactive or active using 0 and 1 respectively in the optional ACTNUM column.

Parameters
  • df_coord – Pandas dataframe with coordinates for all grid cells

  • filename – Path to the EGRID -file to be stored to disk.

Returns

Nothing