Plotting API - Model intersection (Geo-technical)#
This notebook provides the user a guide to how a model intersection can be shown using a Blueback Investigation. Check out the API documentation to view all the functions available for the model intersection view:
Import dependencies :
[2]:
import cegalprizm.investigator as investigator
from cegalprizm.investigator import InvestigatorConnection
from cegalprizm.investigator.views import ModelIntersectionView
Connect to investigator and assign the investigation to a variable :
[3]:
invconnection = InvestigatorConnection(use_licensed_features=True)
inv = invconnection.investigation_from_file("Wells+Model.invpy")
To create a model intersection view of the investigation use the ModelIntersectionView() function with the investigation(inv) as the input parameter. To plot the model intersection, use the .plot() function which takes as input parameters the specific view, in this case the intersection view. You can also provide the width (defaults to 900) and the height (defaults to 600) of the figure.
[3]:
model_view = ModelIntersectionView(inv)
investigator.plot(model_view)
[3]:

By default, the model intersection view will display the first property in your investigation. You can change the property by using the .set_property function:
[4]:
model_view = ModelIntersectionView(inv)
model_view.set_property('Porosity')
investigator.plot(model_view)
[4]:

If you have more than one grid in your investigation you can change the grid you want to display using the .set_grid() function:
[5]:
model_view = ModelIntersectionView(inv)
model_view.set_property('Facies')
model_view.set_grid('GEO Grid')
investigator.plot(model_view)
[5]:

You can change the i-slice you are viewing using the set_i() function:
[6]:
model_view = ModelIntersectionView(inv)
model_view.set_i(50)
investigator.plot(model_view)
[6]:

Similarly, you can change the j-slice using the set_j() function:
[7]:
model_view = ModelIntersectionView(inv)
model_view.set_j(90)
investigator.plot(model_view)
[7]:

Using the .set_north_south() function, you can set the location of a north-south intersection:
[8]:
model_view = ModelIntersectionView(inv)
model_view.set_north_south(456365.0 )
investigator.plot(model_view)
[8]:

Similarly, you can set an east_west intersection using the .set_east_west(value) function:
[9]:
model_view = ModelIntersectionView(inv)
model_view.set_east_west(6785191.0)
investigator.plot(model_view)
[9]:

You can create an intersection through a specific well using the .set_borehole function:
[10]:
model_view = ModelIntersectionView(inv)
model_view.set_borehole('B8')
investigator.plot(model_view)
[10]:

Using the create_borehole_views() function you can generate a model intersection plot for multiple wells:
[11]:
model_view = ModelIntersectionView(inv)
investigator.multi_plot(model_view.create_borehole_views(['B2','B8','B9']))