Project

class rips.Project(pb2_object: PdmObject | None = None, channel: Channel | None = None)

Bases: PdmObjectBase

The ResInsight Project

Methods Summary

case(case_id)

Get a specific grid case from the provided case Id

cases()

Get a list of all grid cases in the project

close()

Close the current project (and open new blank project)

create()

create_grid_case_group(case_paths)

Create a Grid Case Group from a list of cases

export_multi_case_snapshots(grid_list_file)

Export snapshots for a set of cases

export_snapshots([snapshot_type, prefix, ...])

Export all snapshots of a given type

export_well_paths([well_paths, md_step_size])

Export a set of well paths

grid_case_group(group_id)

Get a particular grid case group belonging to a project

grid_case_groups()

Get a list of all grid case groups in the project

import_formation_names([formation_files])

Import formation names into project

import_summary_case([file_name])

Import Summary Case

import_well_log_files([well_log_files, ...])

Import well log files into project

import_well_paths([well_path_files, ...])

Import well paths into project

load_case(path[, grid_only])

Load a new grid case from the given file path

open(path)

Open a new project from the given path

plot(view_id)

Get a particular plot by providing view id

plots()

Get a list of all plots belonging to a project

replace_source_cases(grid_list_file[, ...])

Replace all source grid cases within a case group

save([path])

Save the project to the existing project file, or to a new file

scale_fracture_template(template_id, ...)

Scale fracture template parameters

selected_cases()

Get a list of all grid cases selected in the project tree

set_fracture_containment(template_id, ...)

Set fracture template containment parameters

summary_case([case_id])

Find Summary Case

summary_cases()

Get a list of all summary cases in the Project

surface_folder([folder_name])

Get Surface Folder

view(view_id)

Get a particular view belonging to a case by providing view id

views()

Get a list of views belonging to a project

well_path_by_name(well_path_name)

Get a specific well path by name from the project

well_paths()

Get a list of all well paths in the project

Methods Documentation

case(case_id: int) Reservoir | None

Get a specific grid case from the provided case Id

Parameters:

id (int) -- case id

Returns:

rips.generated.resinsight_classes.Case

cases() List[Reservoir]

Get a list of all grid cases in the project

Returns:

A list of rips.generated.generated_classes.Case

close() None

Close the current project (and open new blank project)

create() Project
create_grid_case_group(case_paths)

Create a Grid Case Group from a list of cases

Parameters:

case_paths (list) -- list of file path strings

Returns:

rips.generated.resinsight_classes.GridCaseGroup

export_multi_case_snapshots(grid_list_file)

Export snapshots for a set of cases

Parameters:

grid_list_file (str) -- Path to a file containing a list of grids to export snapshot for

export_snapshots(snapshot_type='ALL', prefix='', plot_format='PNG')

Export all snapshots of a given type

Parameters:
  • snapshot_type (str) -- Enum string ('ALL', 'VIEWS' or 'PLOTS')

  • prefix (str) -- Exported file name prefix

  • plot_format (str) -- Enum string, 'PNG' or 'PDF'

export_well_paths(well_paths=None, md_step_size=5.0)

Export a set of well paths

Parameters:
  • well_paths (list) -- List of strings of well paths. If none, export all.

  • md_step_size (double) -- resolution of the exported well path

grid_case_group(group_id)

Get a particular grid case group belonging to a project

Parameters:

groupId (int) -- group id

Returns:

rips.generated.generated_classes.GridCaseGroup

grid_case_groups()

Get a list of all grid case groups in the project

Returns:

List of rips.generated.generated_classes.GridCaseGroup

import_formation_names(formation_files=None)

Import formation names into project

Parameters:

formation_files (list) -- list of files to import

import_summary_case(file_name: str = '') FileSummaryCase | None

Import Summary Case

Parameters:

file_name (str)

Returns:

FileSummaryCase

import_well_log_files(well_log_files=None, well_log_folder='')

Import well log files into project

Parameters:
  • well_log_files (list) -- List of file paths to import

  • well_log_folder (str) -- A folder path containing files to import

Returns:

A list of well path names (strings) that had logs imported

import_well_paths(well_path_files=None, well_path_folder='')

Import well paths into project

Parameters:
  • well_path_files (list) -- List of file paths to import

  • well_path_folder (str) -- A folder path containing files to import

Returns:

List of rips.generated.generated_classes.WellPath

load_case(path: str, grid_only: bool = False) Reservoir

Load a new grid case from the given file path

Parameters:

path (str) -- file path to case

Returns:

rips.generated.generated_classes.Case

open(path)

Open a new project from the given path

Parameters:

path (str) -- path to project file

plot(view_id)

Get a particular plot by providing view id

Parameters:

view_id (int) -- view id

Returns:

rips.generated.generated_classes.Plot

plots()

Get a list of all plots belonging to a project

Returns:

List of rips.generated.generated_classes.Plot

replace_source_cases(grid_list_file, case_group_id=0)

Replace all source grid cases within a case group

Parameters:
  • grid_list_file (str) -- path to file containing a list of cases

  • case_group_id (int) -- id of the case group to replace

save(path='')

Save the project to the existing project file, or to a new file

Parameters:

path (str) -- File path to the file to save the project to. If empty, saves to the active project file

scale_fracture_template(template_id, half_length, height, d_factor, conductivity)

Scale fracture template parameters

Parameters:
  • template_id (int) -- ID of fracture template

  • half_length (double) -- Half Length scale factor

  • height (double) -- Height scale factor

  • d_factor (double) -- D-factor scale factor

  • conductivity (double) -- Conductivity scale factor

selected_cases() List[Case]

Get a list of all grid cases selected in the project tree

Returns:

A list of rips.generated.generated_classes.Case

set_fracture_containment(template_id, top_layer, base_layer)

Set fracture template containment parameters

Parameters:
  • template_id (int) -- ID of fracture template

  • top_layer (int) -- Top layer containment

  • base_layer (int) -- Base layer containment

summary_case(case_id: int = -1) FileSummaryCase | None

Find Summary Case

Parameters:

case_id (int)

Returns:

FileSummaryCase

summary_cases()

Get a list of all summary cases in the Project

Returns: A list of rips.generated.resinsight_classes.SummaryCase

surface_folder(folder_name: str = '') SurfaceCollection | None

Get Surface Folder

Parameters:

folder_name (str)

Returns:

SurfaceCollection

view(view_id)

Get a particular view belonging to a case by providing view id

Parameters:

view_id (int) -- view id

Returns:

rips.generated.generated_classes.View

views()

Get a list of views belonging to a project

well_path_by_name(well_path_name)

Get a specific well path by name from the project

Returns:

rips.generated.generated_classes.WellPath

well_paths()

Get a list of all well paths in the project

Returns:

List of rips.generated.generated_classes.WellPath