pycopm.utils.generate_coarser_files module

Utiliy methods to only create the coarser files by pycopm.

pycopm.utils.generate_coarser_files.create_deck(dic)

Main scrip to call the diffeent methods to generate the coarser files

Args:

dic (dict): Global dictionary

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.find_neighbors(dic, ind, i_d, n, s)

Find the neighbouring cells to distribute the removed pore volume

Args:

dic (dict): Global dictionary

ind (list): Indices os cells to distribute the pore volume

i_d (int): Index of the removed cell to distribute its pore volume

n (int): Current increased index for the neighbours search

s (int): Shift to neighbours cells

Returns:

ind (list): Indices os cells to distribute the pore volume

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.get_ijk(dic, i_d)

Return the i,j, and k index from the global index

Args:

dic (dict): Global dictionary

i_d (int): Index of the removed cell to distribute its pore volume

Returns:

i,j,k (int): i,j, and k cell indices

pycopm.utils.generate_coarser_files.handle_clusters(dic)

Create the coarser clusters

Args:

dic (dict): Global dictionary

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_cp_grid(dic)

Handle the pillars and zcord for the coarser grid

Args:

dic (dict): Global dictionary

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_fault(dic, nrwo)

Handle the i,j,k coarser fault indices

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_grid_props(dic, nrwo)

Handle the grid and props sections

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_mapaxes(dic, nrwo)

Keep the mapping so the grids have the same view

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_oper(dic, nrwo)

We also support operations

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_props(dic, nrwo)

Handle the props sections

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_pv(dic, clusmin, clusmax, rmv)

Make sure the pore volume is not created nor destroyed, only distributed

Args:

dic (dict): Global dictionary

clusmin (pandas dataFrame): Mask with all active cells in cluster

clusmax (pandas dataFrame): Mask with at least one active cell in cluster

rmv (pandas dataFrame): Mask to remove cells by the argument flag jump

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_regions(dic, nrwo)

Handle the regions sections

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_schedule(dic, nrwo)

Handle the schedule sections

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_segmented_wells(dic, nrwo)

We also support segmented wells

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_wells(dic, nrwo)

Add the necessary keywords and right i,j,k coarser well indices

Args:

dic (dict): Global dictionary

nrwo (list): Splited row from the input deck

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.handle_zcorn(dic, ir)

Process the zcorn

Args:

dic (dict): Global dictionary

ir (list): Z coordinates from the corners

Returns:

ir (list): Modified z coordinates

pycopm.utils.generate_coarser_files.map_ijk(dic)

Create the mappings to the new i,j,k indices

Args:

dic (dict): Global dictionary

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.map_properties(dic, actnum, d_z, z_t, z_b, z_b_t, v_c)

Mapping to the coarse properties

Args:

dic (dict): Global dictionary

actnum (array): Integers with the active cells

d_z (array): Floats with the corresponding grid DZ

z_t (array): Floats with the top cell z-center position

z_b (array): Floats with the bottom cell z-center position

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.process_the_deck(dic)

Identify and modified the required keywords

Args:

dic (dict): Global dictionary

Returns:

dic (dict): Modified global dictionary

pycopm.utils.generate_coarser_files.write_grid(dic)

Write the corner-point grid

Args:

dic (dict): Global dictionary

Returns:

None

pycopm.utils.generate_coarser_files.write_props(dic)

Write the coarser properties

Args:

dic (dict): Global dictionary

Returns:

None