Logo
Explore Help
Sign In
OilfieldToolsNet/opm-common
4
0
Fork 0
You've already forked opm-common
Code Issues Pull Requests Packages Projects Releases Wiki Activity
Files
1fac541b6e610efb81aba21929a26d6c7987cf49
opm-common/tests/msim/action2.py

10 lines
266 B
Python
Raw Normal View History

Enable running normal ACTIONX keywords from PYACTION The run() function invoked by PYACTION has got a new fifth argument which is a callable the script should utilize to apply the keywords from an ACTIONX keyword. The callable is implemented as C++ lambda which will run the Schedule::iterateScheduleSection() method and make sure an updated SimulatorUpdate variable can be passed back to the simulator.
2022-01-24 13:47:05 +01:00
def run(ecl_state, schedule, report_step, sim, actionx_callback):
Run PYACTION keywords The PYACTION keyword is implemented with a Python module with a run() function in an external module.
2020-03-22 21:02:32 +01:00
wells_shut = False
for well in sim.wells:
if sim.well_var(well, "WWCT") > 0.50:
schedule.shut_well(well, report_step)
wells_shut = True
return wells_shut
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 40ms Template: 1ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API