mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#4867 Rename python examples to avoid mixed case
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
###################################################################################
|
||||
# This example will connect to ResInsight, retrieve a list of cases and print info
|
||||
#
|
||||
###################################################################################
|
||||
|
||||
# Import the ResInsight Processing Server Module
|
||||
import rips
|
||||
|
||||
# Connect to ResInsight
|
||||
resinsight = rips.Instance.find()
|
||||
if resinsight is not None:
|
||||
# Get a list of all cases
|
||||
cases = resinsight.project.cases()
|
||||
|
||||
print ("Got " + str(len(cases)) + " cases: ")
|
||||
for case in cases:
|
||||
print("Case id: " + str(case.case_id))
|
||||
print("Case name: " + case.name)
|
||||
print("Case type: " + case.type)
|
||||
print("Case grid path: " + case.grid_path())
|
||||
|
||||
timesteps = case.time_steps()
|
||||
for t in timesteps:
|
||||
print("Year: " + str(t.year))
|
||||
print("Month: " + str(t.month))
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user