Scripting on ResInsight https://resinsight.org/scripting/ Recent content in Scripting on ResInsight Hugo -- gohugo.io en-us Python Interface https://resinsight.org/scripting/pythoninterface/ Mon, 01 Jan 0001 00:00:00 +0000 https://resinsight.org/scripting/pythoninterface/ ResInsight provides a robust programming interface that allows you to interact with a running ResInsight instance using Python 3. This interface enables you to: Start ResInsight from Python Communicate with a running ResInsight instance Load a ResInsight project file Load data files such as Eclipse EGRID files and summary files Extract data to Python for further processing and automation Export snapshots of graphics For configuration and detailed information, please refer to the ResInsight Python API. Command Line Interface https://resinsight.org/scripting/commandlineinterface/ Mon, 01 Jan 0001 00:00:00 +0000 https://resinsight.org/scripting/commandlineinterface/ ResInsight supports several command line parameters that can be used to automate some tasks using shell scripts. Command line parameters are prefixed using a double dash. This convention is used on all platforms to make it possible to reuse scripts across different platforms. See GNU Standards for Command Line Interfaces. Examples on how command line options are used are given below Command line options General Parameter Description --help, --? Displays help text and version info --project <filename> Open project file <filename>. Command File https://resinsight.org/scripting/commandfile/ Mon, 01 Jan 0001 00:00:00 +0000 https://resinsight.org/scripting/commandfile/ The command file interface allows a sequence of specified commands to be run in order from the command line. The interface is used by supplying the command file as a command line parameter. Once the command file is finished executing, ResInsight will exit. It is possible to use these commands directly from a Python script. For further details, please see the ResInsight Python API. Command List Case Control Commands openProject closeProject setStartDir loadCase createGridCaseGroup createStatisticsCase replaceCase replaceSourceCases Export Commands setExportFolder exportMultiCaseSnapshots exportSnapshots exportProperty exportPropertyInViews exportWellPathCompletions exportSimWellFractureCompletions exportMsw exportWellPaths exportVisibleCells exportFlowCharacteristics Other Commands runOctaveScript setMainWindowSize computeCaseGroupStatistics setTimeStep scaleFractureTemplate setFractureContainment createMultipleFractures createLgrForCompletions createSaturationPressurePlots Syntax The command file is comprised of a set of commands to be executed in order. Octave Interface https://resinsight.org/scripting/octaveinterface/ Mon, 01 Jan 0001 00:00:00 +0000 https://resinsight.org/scripting/octaveinterface/ ResInsight provides a flexible interface to Octave including: Octave functions that communicates with a running ResInsight session Features to simplify management and editing of Octave scripts from ResInsight Commands to execute scripts using Octave. The Octave functions are documented in Octave Interface Reference. Note: The Octave interface does not support Flow diagnostics and Injection flooding results in addition to Geomechanical cases. Octave Script Management Octave scripts are available in the Scripts folder in the Project Tree. Octave Interface Reference https://resinsight.org/scripting/octaveinterfacereference/ Mon, 01 Jan 0001 00:00:00 +0000 https://resinsight.org/scripting/octaveinterfacereference/ Introduction To identify a ResInsight case uniquely in the Octave script, an integer Id (CaseId) is used. This Id can be retrieved in several ways, but there are two main modes of operation regarding this for a particular octave script: Either the script is designed to work on a single case (the “Current Case”), or the script is designed to access the selection and traverse the cases by itself. Note: The Octave interface does not support Geomechanical cases and flow diagnostic results.