Disclaimer Use of this product is governed by the License Agreement. Schlumberger makes no warranties, express, implied, or statutory, with respect to the product described herein and disclaims without limitation any warranties of merchantability merchantability or fitness for a particular purpose. Schlumberger reserves the right to revise the information in this manual at any time without notice.
Trademarks Petrel, Ocean and Ocean for Petrel are trademarks of Schlumberger. Microsoft® and Windows® are registered trademarks of Microsoft Corporation.
Table of Contents Table Table of Contents Contents ................................. .................................................. ................................. ................................. .................................. ........................... ..........3 What is Ocean for Petrel? ................................................................................................. 1 Ocean for Petrel Distribution ...................................................................................... 1 Product Licenses ................... ......... ................... ................... ................... ................... ................... .................. ................... ................... .................. ......... 2 Ocean for Petrel Documentation ................................................................................ 2 Operating Environment................... .......... ................... ................... .................. ................... ................... ................... ................... .................. ......... 2 Petrel Petrel 2010.1 2010.1 ................................ ................................................. ................................. ................................. .................................. ........................... .......... 3 Ocean API Stability.................................................................................................... 3 Summary of Ocean Elements ........................................................................................... 4 Ocean Architecture................... ......... ................... ................... ................... ................... ................... ................... ................... ................... ............... ..... 4 Ocean Core ............................... ................................................ .................................. ................................. ................................. .............................. ............. 5 Ocean Services Services ............................... ............................................... ................................. ................................. ................................. ......................... ........ 5 Ocean for Petrel Petrel ................................. ................................................. ................................. ................................. ................................. ...................... ..... 7 New features in Ocean for Petrel 2010.1 .......................................................................... 9 Domain Domain API ............................... ................................................ .................................. ................................. ................................. .............................. .............9 Visualiz Visualizatio ation n ................................. .................................................. ................................. ................................. .................................. ......................... ........ 17 Other Other .................................. .................................................. ................................. ................................. ................................ ................................ .................... .... 19 Other Other Changes Changes ................................ ................................................ ................................. ................................. ................................. ....................... ...... 20 Known Issues in Ocean for Petrel 2010.1 ...................................................................... 22 New features in Ocean for Petrel 2009.2 ........................................................................ 24 Domain Domain API ............................... ................................................ .................................. ................................. ................................. ............................ ........... 24 Visualiz Visualizatio ation n ................................. .................................................. ................................. ................................. .................................. ......................... ........ 26 Other Other .................................. .................................................. ................................. ................................. ................................ ................................ .................... .... 26 New features in Ocean for Petrel 2009.1 ........................................................................ 27 Domain Domain API ............................... ................................................ .................................. ................................. ................................. ............................ ........... 27 UI and Look & Feel .................................................................................................. 36 Installation and Un-installation ................................................................................. 39 Appendix A: Migration to Simulation Results on the Petrel Results Tree .................. ......... ........... 40 Introducti Introduction on ............................... ................................................ .................................. ................................. ................................. ............................ ........... 40 Petrel Simulation Results......................................................................................... 40 Issues you may face ................................................................................................ 41 Appendix B: Use of IObservableElementEnumerable instead of INotifyingEnumerable ................................. .................................................. ................................. ................................. ................. 47 Appendix C: Third-party Components Components Deployed with Petrel: Petrel: Avoiding Version Conflicts Conflicts ................................. ................................................. ................................. ................................. ................................. ............................ ........... 48 Contacting the Ocean Team ........................................................................................... 50
What is Ocean for Petrel? Ocean is an open, proprietary application development framework targeted for E&P software. Ocean provides a powerful software development development environment through the extensive API footprint, through the .NET based architecture and the associated .NET tools. The Petrel application is implemented on the Ocean framework, and is bundled with Ocean and Ocean for Petrel. Ocean O cean for Petrel enables access to the key Petrel domain data types, as well as user interface and interaction features. It also enables extensions of Petrel, allowing addition of new domain data types with renderers, new windows, and new algorithmic and interactive processes. processes. Ocean for Petrel offers the opportunity opportunity to extend, interoperate with, and re-use many of the features of Petrel in custom workflows. This expedites delivery of technological innovation and significantly reduces the time-to-market. This document contains the release notes of Ocean f or Petrel 2010.1. The features f eatures that are new with this release are listed in the section New features in Ocean for Petrel 2010.1, page 2010.1, page 9. For 9. For completeness, we have also integrated the summary of the news in the previous version over the one before that in the section New features in Ocean for Petrel 2009.2 (page24) and New features in Ocean for Petrel 2009.1 (page 27) (page 27).. A summary of known issues in Ocean for Petrel 2010.1 can be found on page 22.
Ocean for Petrel Distribution All the elements elements necessary to develop develop Ocean for Petrel plug-ins are are available available through the Ocean Portal. This consists mainly of: Petrel 2010.1 (32bit and 64bit) and Ocean for Petrel 2010.1 API binaries Demo Data Set (Gullfaks) Ocean for Petrel 2010.1 SDK documentation integrated with Visual Studio and in stand-alone Ocean Help files (.chm). Ocean for Petrel Wizards (Visual Studio 2008 Plug-in), Sample Code and Reference Applications showing patterns for how to use the API
What is Ocean for Petrel?
Product Licenses Ocean is a licensed feature of Petrel. A developer‟s license is required to create new Ocean modules. If you run Petrel 2010.1 with an Ocean for Petrel Developer‟s License, all licensable fea tures of Petrel will be available. available. The license may be used for testing t esting the interoperability interoperability of developed Ocean modules with Petrel. The enabled Petrel features may not be used for any other purpose, such as offer or perform commercial services and perform commercial or competitive analysis analysis of Schlumberger‟s Schlumberger‟s software. Furthermore, Petrel will configure itself to go into Developer‟s mode. This implies that the Petrel application shell and all hard -copies will be watermarked. Any projects saved whilst in Developer‟s Devel oper‟s mode will be tagged. Such projects will continue to be watermarked even if you load these into a fully featured version of Petrel at a later point.
Ocean for Petrel Documentation The Ocean for Petrel help files (.chm and .HxS files) are generated from the source code at build time, and is the ultimate source of API documentation. Please refer to this for the definitive list of API features.
Operating Environment Ocean for Petrel 2010.1 (3.2010.0.0) has been validated on Windows XP, Windows XP-64, and Windows Vista 64. Ocean for Petrel 2010.1 is built on top of Ocean Core, version 3.2010.0.0, and on Ocean Services, version 3.2010.0.0. The following 3 rd party software is needed for developing Ocean for Petrel modules: Windows XP SP2 (32 or 64 bits) or Windows Vista 64 operating system Visual Studio 2008 Standard/Professional .NET Framework 3.5 In addition OpenInventor (version 7.2) comes bundled with Ocean for Petrel 2010.1. Note that the OpenInventor (3D graphics) toolkit is an integral part of the Ocean for Petrel API. I t is not separately licensed, but can only be used in the context of Ocean for Petrel. OpenInventor is provided provided by VSG (Visualization (Visualization Sciences Group). If a stand-alone version of OpenInventor is required, you need to purchase a license directly from VSG. More information may be found at www.vsg3d.com www.vsg3d.com..
What is Ocean for Petrel? (See Appendix C for full list of third-party libraries deployed with Petrel.) The Ocean for Petrel binaries were built with Visual Studio 2008 with Service Pack 1 installed. They target the .NET Framework version 3.5. Petrel 2010.1 installs in parallel with earlier versions, so installers need to be updated for 2010.1 with the following environment variables: -
Ocean2010Home
-
Petrel 2010.1 x32 = Ocean2010Home_win32
-
Petrel 2010.1 x64 = Ocean2010Home_x64
The Petrel product codes for 2010.1 are: -
win32 = {D3723E01-35AB-4FD1-A496-07BB91C677D2}
-
x64 = {05865F9E-7870-46F6-8E35-7168982452A1}
Petrel 2010.1 Please refer to Petrel 2010.1 documentation for information regarding the features shipped with Petrel 2010.1.
Ocean API Stability We are committed to compile-time compatibility in the Ocean API for a minimum of two full yearly releases. This enables Ocean Applications to easily migrate to subsequent commercial versions of Ocean for Petrel. API‟s that will be replaced and phased out in the future are first deprecated for at least one full yearly release (included in the overall two years minimum stability). Deprecated APIs will be marked [Obsolete] in the SDK documentation and your compiler will give warnings if you continue to use them; but, we will continue to support and test them until they are removed. There is an exception to this commitment, however: In some cases we expect changes in the underlying API implementation that may require changes in the API. In these cases we have tagged the API with the keyword [SubjectToChange] in the SDK documentation. Ocean for Petrel 2010.1 is built on top of Petrel 2010.1.
Summary of Ocean Elements
Summary of Ocean Elements Whilst the definitive documentation for API features is available in the help files, bundled in the Ocean for Petrel 2010.1 SDK installer, this section gives an overview of the fundamental building blocks of Ocean.
Ocean Architecture The Ocean architecture is illustrated in Figure 1. The foundation of the overall system is Ocean Core. Ocean Core provides the essential features that are used by components at a higher level in the architecture, e.g. module lifecycle management and data source management. The next level in the architectural hierarchy is the Ocean Services, comprising features such as coordinate transformations and unit conversions. Ocean Services can only have dependencies to Ocean Core or to other Services. The third level introduces the product family, which in this case is Ocean for Petrel. It provides access to Petrel data types, the Petrel UI and Petrel workflow management. Ocean Applications may use all of these API‟s, as illustrated in Figure 1.
Product Productfamily: family: Application Applicationshell shell Domain Domainobjects objects Data Datasources sources/ bulk / bulkaccess access Processes Processes Windows Windows Toolbars Toolbars Events Events Interaction Interaction
Figure 1 Ocean API architecture
Summary of Ocean Elements
Ocean Core The Ocean Core consists of a set of basic principles and strategies, interfaces and implementations, all designed to guide the development of all Ocean applications such that they are all aligned to the same basic mold. The Ocean Core APIs exposed are: Module Lifecycle Service Locator Basic Logging Data Source Manager and Data Source Workspace Event Transactions The Ocean Core uses some of the Microsoft Enter prise Library‟s application blocks, namely Logging and Exception Handling. Logging is configurable.
Ocean Services In this version of Ocean, six services are provided, namely Basics, Geometry, a Unit Service, Domain Object Hosting, Catalogs Service, and a Coordinate Service.
Basics This service provides applications with basic t ypes, representing concepts such as Extents, Indices and Index ranges, together with basic numerical algorithms.
Geometry This service provides applications with fundamental definitions of geometry, e.g. basic types such as Angles, Points and Lines, Planes and Boxes.
Unit Service The Unit Service consists of a catalog of unit measurements that is organized hierarchically. Unit measurements (e.g. “length”) are associated with units (e.g. “meters” or “feet”), also organized in a catalog. A third catalog keeps pairs of unit and unit measurements defining unit systems (e.g. “metric” or “imperial”). The unit conversion service provides converters between units
Summary of Ocean Elements defined in the catalog to transform values. In the Ocean domain API all data are delivered and received in base 1 SI units. Note in particular that the base SI unit for seismic traveltime is seconds (not milliseconds) and for permeability is m2 (not Darcy or milli-Darcy; 1 Darcy = 0.9869233E-12m 2).
Catalogs Service This service allows applications to look up log channels based on channel names or unit measurements.
Coordinates Service This service provides the ability to cr eate converters to transform data between coordinate reference systems. As of 2010.1, the new Slb.Ocean.Coordinates service, based on the ESRI projection engine, is fully integrated with Petrel. The new service offers many new features, such as an API to create coordinate reference systems from “well known text” and APIs to navigate Petrel‟s coordinate system catalogs.2 The new service supports both the ESRI engine (integrated with Petrel) and the legacy Mentor engine. But, the Mentor engine is no longer loaded into Petrel by default. The old Slb.Ocean.CoordinateSystems service works solely with t he Mentor engine. This service is deprecated. The assembly is still available in the \Public folder but it no longer appears in the “Additional reference” settings of the Ocean SDK Wizard . Again, the Mentor engine is no longer loaded by default into Petrel, so a plug-in that needs to use the old service must load the Mentor engine itself.
Domain Object Hosting Ocean provides high-level data access to entities representing data, irrespective of the data source, called Domain Objects. The framework allows a developer to encapsulate application-specific validation or usage rules and hide location and complexities related to the data store. Domain Objects typically act as intermediaries between a persistent data store and application code. They map from the data store representation to a format required (and desired) by applications. Their object model is often quite different from the model used by the underlying data store – they hide database implementation details and differences between database vendors from the application. Domain Objects do not require persistence
1
Base SI unit are defined as the SI unit, which has a scaling factor of 1.0 and an offset of 0.0. A homogeneous unit system promotes cross-computation. Example: a product of two base SI units values yields a value in a base SI unit of a new measurement. 2 A new stand-alone component of Petrel – the Coordinate System Manager (CSM) – is available in custom Petrel installations. This allows Petrel end-users to manage coordinates catalogs via a GUI.
Summary of Ocean Elements – it is possible to have in-memory objects that contain business logic but do not save their state to a persistent data store. Domain Object Hosting provides support for transaction management allowing the user to lock objects before they are modified and commit or abandon changes after modification. (Note that Ocean for Petrel native Domain Objects do not currently support abandoning transactions.) Domain Object Hosting provides a notification event mechanism to which a module can subscribe. The object will then be notified when the object changes or is being changed. This means that domain object writers create new data types that follow the same usage pattern as the Petrel data exposed through the API.
Ocean for Petrel Extending the Petrel User interface, the UI Infrastructure The Petrel user interface (UI) uses MS WinForms. A set of API‟s have been exposed so that it can be tailored to the needs of new applications. Ocean for Petrel provides convenience classes in order to display messages, status information, and progress information. It also allows for examining the Petrel project state, and change and manage the different UI elements exposed from Petrel. The UI Infrastructure API provides interfaces to access the various elements of the Petrel Explorer. You can add new objects to the trees, or customize existing ones. All tree interfaces provide current selection and selection change events, so the module can access the state of a particular tree or be notified whenever a change is produced (i.e. new object is select/deselected). The content of display windows in Petrel are synchronized with objects and elements selected in the Petrel Explorer. The window manager interface handles the display window area by reporting its current state, notifying windows state changes with events, and managing collections of windows. Ocean for Petrel provides APIs for custom rendering of new domain objects in selected 2D windows and in the 3D Petrel window, and for creating new windows. Objects rendered with 2D graphics use .NET Graphic Library (GDI+), while 3D rendering is done with OpenInventor.
Interoperating with Petrel data types, the Domain API The Ocean for Petrel Domain API exposes and offers a number of data types and services to manage Petrel data. These services include the ability to navigate the data, to programmatically discover relationships between data types, to enable additions of new extension objects to existing Petrel objects, as well as a data event model. For a full overview of the current capabilities, please refer to the API documentation. A brief description of some of the data types follows: : This API gives access to the 3D Grid model of Petrel. Grid geometry, properties, PillarGrid faults, horizons, segments and zones are accessed through this main class.
Summary of Ocean Elements : provides support classes to manipulate points, polylines, and surfaces. The Shapes PointSet and Surfaces classes also provide access to properties associated with the shape. : Borehole is the main class in this API, and gives access to Logs, Trajectory, Well Completions and Markers, from which it is possible to identify the relationships to zones, horizons and faults. : SeismicCollection and InterpretationCollection act as the containers for seismic Seismic surveys and faults and horizons interpreted on seismic data, respectively. The API supports 2D and 3D seismic data and 2D and 3D interpretation. Traces can be accessed either through an enumerator or randomly from a relative positional index. In addition, it‟s possible to access sub-cubes of 3D data. : provides interfaces to access reservoir simulation data in Petrel: Streamlines, Simulation
Summary vectors, Grid results, Observed (production) data, simulation Cases, VFP tables, Black oil Fluid and saturation functions. ISimulationRoot acts as the container for all domain objects in the simulation domain. ISimulationManager and EclipseFormatSimulator allow to integrate a custom simulator into Petrel. The external simulator can access most static input data through the simulation Case, but it still needs to follow the Eclipse format for dynamic data and simulation output.
Petrel Processes and Workflows, the Workflow API New processes can be created, and can be executed from Petrel‟s Process Diagram, or as part of a Petrel Workflow as defined in Petrel‟s Workflow Editor. The API essentially enables custom processes to take part seamlessly in Petrel‟s workflows. Furthermore; Samplers, Optimizers and Proxies can be implemented and integrated as algorithms in Petrel‟s uncertainty and optimization framework. The process may have a UI auto-constructed by Ocean for Petrel from a set of arguments, but applications are also free to create their own custom UI‟s
New features in Ocean for Petrel 2010.1
New features in Ocean for Petrel 2010.1 Domain API Reservoir Engineering – Plug-in Simulator Ability to create cases for Native and Plugged-in Simulators Namespace: Slb.Ocean.Petrel.Simulation Create for WellKnownSimulator Create for an EclipseFormatSimulator
Note that Simulation Case was refactored and now only one simulator can belong to a Case. The case arguments/properties can be then set programmatically to define a simulation case.
Support for static reservoir data on simulation case Namespace: Slb.Ocean.Petrel.Simulation Get/Set on Grid Grid properties Functions by regions: o Black oil fluid o Rock compaction o Rel. perm & capillary pressure Development strategy Grid export format Various settings
Ability to query the simulator with Case as parameter Namespace: Slb.Ocean.Petrel.DomainObject.Simulation This enables an Ocean client to determine which simulator a Case object is associated with.
New features in Ocean for Petrel 2010.1
Full access (CRUD) to Rock Compaction Domain Object Namespace: Ocean.Petrel.DomainObject.Simulation.RockCompactionFunction Ocean.Petrel.DomainObject.Simulation.RockPhysicsCollection Create new rock compaction curves Read the properties and records of existing curves Access / assign to simulation case
Type Safe Eclipse Keyword API Namespace: Slb.Ocean.Petrel.Simulation.EclipseKeywords The enhanced keyword API features a C# code generated library for programmatic interaction with an ECLIPSE deck. Data is be accessed through classes, data records and typed data/value fields without the need to parse the deck file. It exposes more than 700 type safe read/write/update Keywords. This is a very useful API for convertor code for plugged-in simulators or for controlled manipulation of an ECLIPSE deck. ECLIPSE DECK
Ocean Keyword
Access to Eclipse Native Keyword Editor Namespace: Slb.Ocean.Petrel.Simulation It is possible to allow the built in keyword editor to be used in the context of an EclipseFormatSimulator
Grid property results moved to results pane The simulation Grid (or 3D) results were moved from the models tree to the results tree in Petrel 2010.1. Hence Ocean has put in place an API to read the ”new” simulation results. One property, as we used to know it from t he models tree, can now be visualized by selecting the property type, a simulation case and a timestep. The API follows the same ”paradigm” as Petrels visualization. This API now resembles the simulation results API for summary vectors. See appendix at the end of this document for more details about these changes.
New features in Ocean for Petrel 2010.1
Volume Calculation Results Namespace: Slb.Ocean.Petrel.DomainObject.Simulation Volume case and result type yields a volume result.
Results can be filtered to give partial volume results: a list of different filters of each type can be passed to the GetResult method to generate a partial result for the area specified by the filters.
Access proxy results for summary vectors and volume calculation This API reads summary vectors and volume calculation results that are generated by an Ocean plugged-in proxy. A proxy is a small mathematical model that tries to approximate a complex or large simulation. The example below shows how to read the f irst result (first reporting time step in the simulation) of all approximated proxy realizations, for all variables that are specified in the uncertainty workflow for a specific proxy summary result (for example: ”Water cut”) and result category (for example ”Field” or a certain well). Similar examples can be made for proxy volume calculation results, but without the time dimension."
New features in Ocean for Petrel 2010.1
Limited access to Development Strategy Create Namespace: Slb.Ocean.Petrel.DomainObject.Simulation The new API provides support for creating only a limited number of rules in a development strategy: - A rule can only be defined for one well. - Rules are applied at timesteps. - A development strategy is created with a name, type and a list of timesteps (which incorporates rules and wells) A handful of rules can be applied at timesteps - Reporting frequency - History rate control - Maximum ratio - Minimum production rate - Pressure production control - Rate production control - Water cut - Water injection control - Well status
Development strategies can also be deleted.
Vertical Flow Performance (VFP) Tables Namespace: Slb.Ocean.Petrel.DomainObject.Simulation Ability to have read access to pressure drop model / Vertical flow performance (VFP) table.
Case Variable Filters Namespace: Slb.Ocean.Petrel.DomainObject.Simulation Plug-in can have access to case variable filters
Aquifer DO Namespace: Slb.Ocean.Petrel.DomainObject.Simulation Access to Identifiable Aquifer DO and get/set on Simulation Case.
Depth Varying Completions Namespace: Slb.Ocean.Petrel.DomainObject.Well.Completion Ability to access depth-varying tubing (special/new type of WellPetrelCompletions).
New features in Ocean for Petrel 2010.1
Shapes Domain Index based access to Surface attributes Namespace: Slb.Ocean.Petrel.DomainObject.Shapes.[Dictionary]SurfaceProperty. SurfaceProperty and DictionarySurfaceProperty domain objects now have an indexer to get or set the surface property sample value for a given i,j position in the grid. These domain objects now also have a way to get and set many samples in one go with the Samples and AllSamples properties. These methods have been added for increased usability and performance.
Trimesh Patches Enhancement Namespace: Slb.Ocean.Petrel.DomainObject.Shapes.TriangleMesh TriangleMesh mesh geometry as an enumeration of IndexedTriangleMesh rather than one single IndexedTriangleMesh.
Seismic Domain Change in Attribute Generator Namespace: Slb.Ocean.Petrel.Seismic The Seismic attribute generator API was refactored and is now exposed as an abstract class, and not an interface anymore. The attribute generator provides a mechanism to trigger the recalculation of the attribute when a parameter has changed and provides a way to validate inputs.
Pre-Stack Seismic Namespace: Slb.Ocean.Petrel.DomainObject.Prestack A façade for generic prestack seismic datasets The Ocean API exposes a façade to access prestack data and to allow interoperability between different providers. Provider developers can implement their own backend through the backend API. Petrel 2010.1 comes with a simple 3D renderer and a default SEGY backend.
Set Default Seismic Data Location Namespace: Slb.Ocean.Petrel.DomainObject. Seismic.SeismicCollection It is programmatically possible set the default location for Seismic data
Create SeismicCube in Given Location Namespace: Slb.Ocean.Petrel.DomainObject. Seismic.SeismicCollection Possibility to create a SeismicCube outside the Petrel project directory.
(Dictionary)HorizonProperty Faster Indexer Namespace: Slb.Ocean.Petrel.DomainObject. Seismic.HorizonProperty2D and 3D Property access for HorizonInterpretation 2D and 3D has been enhanced for better performance and usability. Indexers have been added and many samples can be get or set in one go.
Property Modeling Redesign of the Geometrical Property Modeling API Namespace: Slb.Ocean.Petrel.PropertyModeling Re-design of existing API to follow the same patterns used by the 2010.1 SeismicAttribute API and new Petrophysical/Facies Property Modeling APIs
Kriging Algorithm Namespace: Slb.Ocean.Petrel.PropertyModeling. WellKnownPetrophysicalModelingAlgorithms Expose the Petrel Kriging algorithm as a workstep accessible through an Ocean API
Sequential Gaussian Simulation Algorithm Namespace: Slb.Ocean.Petrel.PropertyModeling. WellKnownPetrophysicalModelingAlgorithms Expose the Petrel Sequential Gaussian Simulation property population algorithm.
Sequential Indicator Simulation Algorithm Namespace: Slb.Ocean.Petrel.PropertyModeling.WellKnownFaciesAlgorithms Expose the Petrel Sequential Indicator Simulation algorithm as a workstep.
Gaussian Random Function Algorithm Namespace : Slb.Ocean.Petrel.PropertyModeling.WellKnownPetrophysicalModelingAlgorit hms
Expose the Petrel Gaussian Random Function property modeling algorithm.
Access statistics of dictionary property – i.e., the statistics that are displayed on the Disc. stat. of the Settings dialog for a DictionaryProperty.
Plug-in architecture for facies property modeling Namespace: Slb.Ocean.Petrel.PropertyModeling Allow to add your own algorithm for facies property modeling
Plug-in architecture for petrophysical property modeling Namespace: Slb.Ocean.Petrel.PropertyModeling Allows to add your own algorithm for petrophysical property modeling
Structural Modeling Initial API in 2010.1 Petrel 2010.1 comes with a new Structural Modeling module. Ocean exposes an initial API for its objects. - Fault model domain object. - Horizon model domain object. - Zone model domain object.
Well domain Get Active Check Shot Namespace: Slb.Ocean.Petrel.DomainObject.Well.Borehole Ability to get the current active CheckShot.
New features in Ocean for Petrel 2010.1
Spatial Data Transfer in Native Coordinate Reference System (CRS) Namespace: Slb.Ocean.Petrel.DomainObject.DataTransfer Starting with Petrel 2010.1, Petrel objects will support transformation between different coordinate systems. Ocean provides new APIs to create and update Petrel Objects with data in Native Coordinate Reference System (different than the project CRS). For example, the following code sample imports a PointSet from an external CRS: using Slb.Ocean.Petrel.DomainObject.DataTransfer.Shapes; SpatialContext context = new SpatialContext (externalCRS, SpatialUnitsPolicy .ContextOverridesSI); PointSet ps = collection.CreatePointSet( "Imported PS"); Point3[] points = new Point3[] { /* … */ }; // fill with points in external CRS PointSetSpatialAccess pssa = new PointSetSpatialAccess (context); pssa.SetPoints(ps, points); // points are converted to project CRS
ATTENTION: The Project CRS is much more important starting in Petrel 2010.1. When opening a new project or an old project where the CRS has not been set, end-users must explicitly select either a CRS or NULL. For projects with a non-NULL CRS, Petrel now performs conversions when transferring spatial data via File Import/Export and RPT to a destination with a different CRS. For this reason, plug-ins should rarely (if ever) change the Project.CoordinateReferenceSystem property – and if they do, must ensure that the enduser is aware of the change. Most native Petrel data are now “spatially-enabled” (support spatial conversions on transfer). This includes, 2D seismic and interpretation, Well Data (head, deviation, markers, check shots …), Point data, Polygons, Faults, Satellite images, etc. However, a few native Petrel data types (notably 3-D Seismic) are not spatially-enabled in 2010.1. Likewise, there is no way for Ocean Custom Domain Objects to declare themselves as spatially-enabled. Nonspatially-enabled objects will not appear in the Reference Project Tool GUI when the primary and reference projects have different CRSs. A new API in 2011.1 will allow Ocean Custom Domain Objects to participate in such conversions. Likewise, the current plan is that native 3-D Seismic objects will be spatially-enabled in 2011.1, and, these objects will be added to the Ocean Spatial Data Transfer API.
FaultModel domain Namespace: Slb.Ocean.Petrel.DomainObject.FaultModel 2010.1exposes the fault model object, which can be found in the models tree.
New features in Ocean for Petrel 2010.1
Pillar Grid Slice intersection service Namespace: Slb.Ocean.Petrel.DomainObject.PillarGrid.IPillarGridIntersectionService Slb.Ocean.Petrel.DomainObject.PillarGrid.IHorizonIntersectionService
Service to calculate intersections between Grid/Horizon and f acet.
Visualization “New Window” Menu Entry Positioning Namespace: Slb.Ocean.Petrel.UI.Tools Ensure custom "New Window" menu items are positioned correctly in the Windows menu
Support of workflow variables in Worksteps with Custom User Interface Namespace: Slb.Ocean.Petrel.Workflow Workstep with custom user interface (UI) supporting workflow value and reference variables. A complete walkthrough with detailed examples is available in the online help.
Performance improvement of IToggleWindow Namespace: Slb.Ocean.Petrel.UI.ToggleWindow Slb.Ocean.Petrel.UI.MapWindow Slb.Ocean.Petrel.UI.WellSectionWindow Slb.Ocean.Petrel.UI.InterSectionWindow
Significant performance improvement over the IToggleWindow interface. Plug-in window implementations should no longer implement the IToggleWindow Interface directly, and should instead inherit from the new ToggleWindow base class. Through this API, windows can specify the types of domain objects they can visualize, thus leading to f ewer API calls and significant performance improvements when opening custom windows in large Petrel projects.
New classes for well-known Petrel windows Namespace: Slb.Ocean.Petrel.UI The interfaces representing the well-known Petrel windows, have been replaced with class representations (MapWindow, Window3D, IntersectionWindow, W ellSectionWindow, FunctionWindow). In addition to the previous functionality, each of these windows now provides a VisibleObjects property, representing a collection of domain objects currently set to visible in the window.
New features in Ocean for Petrel 2010.1
Control of the Drawing Order in an IMapRenderer Namespace: Slb.Ocean.Petrel.UI Support drawing order for custom objects in multi-pass rendering of the Petrel Map Window, Intersection Window, and W ellSection Window.
Synchronized Redraw Of 3D Windows Namespace: Slb.Ocean.Petrel.UI A redraw-method to force an immediate and synchronized redraw of the 3D window in Petrel.
InteractiveCompletionTrackEditing Namespace: Slb.Ocean.Petrel.UI.WellSectionPickedPoints Slb.Ocean.Petrel.UI.WellSectionRendererContext In the Well Section Window, the mouse action-related methods overridden in custom window modes are invoked only when there are mouse actions on log tracks. These methods are not invoked when there are mouse actions on completions tracks. Ocean should be extended to cover interaction events also in the completions tracks
Windows are IIdentifiable Namespace: Slb.Ocean.Petrel.UI Petrel windows are now IIdentifiable
Custom Advanced Toolbar Controls Namespace: Slb.Ocean.Petrel.UI.Tools The API provides a mechanism to add custom advanced control in toolbars.
Standard Petrel Windows.Forms Controls Namespace: Slb.Ocean.Petrel.UI.Controls This API exposes many of the Windows.Forms controls used in the Petrel GUI for use by plug-ins. Examples include, ColorPicker and ColorPickerPanel, ToolTip controls, etc.
New features in Ocean for Petrel 2010.1
Other Time Playable Cross Plot And Function Domain Objects Namespace: Slb.Ocean.Petrel.DomainObject.Analysis.Function.Date Slb.Ocean.Petrel.DomainObject.Analysis.Function.UseDate Slb.Ocean.Petrel.DomainObject.Analysis.CorrelationData2D.Date Slb.Ocean.Petrel.DomainObject.Analysis.CorrelationData2D.UseDate
Correlation data (cross plot) and function domain objects are now time playable
Import Multi File Namespace: Slb.Ocean.Petrel.IO It is now possible to import of multiple files
Ocean Store Licensing A white paper with examples is provided in the on line help of the SDK to describe how to implement licensing to participate in the Ocean Store.
PetrelLicenseCheck Namespace: Slb.Ocean.Petrel.Basics.PetrelLicenseAttribute Slb.Ocean.Petrel.Basics.PetrelLicense Slb.Ocean.Petrel.Licensing.LicensingService Ocean-based modules can check if certain Petrel module licenses are available
DataManagement The framework now offers a way with which a plug-in effectively can add a data source to the data source manager of both the primary and the reference project. This in turn means that the custom data source no longer has to be Serializable. The mechanism to do that is to make a class that derives from Slb.Ocean.Petrel.Data.DataSourceFactory and to register it with Slb.Ocean.Petrel.PetrelSystem. The framework invokes the GetDataSource() method of the factory for each project, including the reference project. Data sources returned from the factory will be added to a data source manager by the framework and should not be Serializable. Please consult the (enhanced) Slb.Ocean.Petrel.Data Namespace documentation for more information and code samples.
New features in Ocean for Petrel 2010.1
Other Changes The well section window will be completely replaced in 2011.1. Well Section Window related APIs are tagged obsolete in Ocean for Petrel 2010.1 , but there is no alternate API at the moment. The new Window and the new API will be available in pre-commercial snapshots of Ocean for Petrel 2011.1. Petrel‟s color table behavior has changed in 2010.1. Ocean supports these changes (1) Custom Domain Objects now only have a color table tab in the Settings dialog if they support private color tables. (2) Custom Domain Object private color tables now have an opacity curve. (3) Inline documentation describing the old Petrel color table behavior was removed. The Ocean for Petrel inline documentation is now built using Sandcastle. You should notice usability improvements. Since Petrel 2009.2, the ESRI coordinate service engine is now a standard feature of Petrel. ESRI coordinate systems are now available in the Coordinate reference system selection dialog accessed through Project Settings -> Units and coordinates > Coordinates. This dialog now also allows entry of custom coordinate systems expressed as well-known-text. To use the new ESRI engine features programmatically, you must use the new Coordinates service delivered in the new version of Ocean Core and Services – namespace Slb.Ocean.Coordinates. The WorkspaceOpened event happens now later when project loads. This means that the Ocean for Petrel API is now fully functional when the event is raised. The fracture model has changed in Petrel 2010.1. The Create fracture network process is creating fracture networks under Grid objects; the output object, called “Fracture network” in the Models tree is a new container not yet accessible through the Ocean API. Under this container, resides the Ocean FractureNetwork, called "Discrete fractures", together with another set of fractures, "Implicit fractures", not accessible from the Ocean API. The Ocean API still supports editing and creating FractureNetworks under ModelCollection and Project, but only support editing FractureNetworks under Grid (with restrictions, see Petrel documentation , fractures sets are read-only, discrete fractures cannot be deleted directly) . The generated Installer Project no longes uses Custom Actions to register and handle the modules in the setup package. Instead there is a new InstallModules.xml file generated into the project, which handles everything which is related to the module registration, probing paths, trusts, etc. For more details on this, please see the UsingTheWizard.pdf installed by the SDK. The Ocean Wizard no longer supports Visual Studio 2005. Only Visual Studio 2008.
Known Issues in Ocean for Petrel 2010.1 The OceanSDK installer now installs the Ocean for Petrel controls to the Visual Studio control Toolbox.
Known Issues in Ocean for Petrel 2010.1
Known Issues in Ocean for Petrel 2010.1 In all Petrel versions up to and including Petrel 2009.2, the WorkspaceOpened event of the Slb.Ocean.DataManager class was raised before Petrel was actually finished loading and converting (old) project data. This did lead to a number of issues, one of them being that some domain data obtained through the API in a handler of this event was incorrect and that unit conversions could fail. In Petrel 2010, this has been fixed; the event is now raised later in time. But this also means that the framework now can call into a plug-in before this event has been raised. A plug-in which initializes its internal state in an handler of this event might fail to function if this state is needed during these early calls from the. Typically these are Process.OnActivateCore, IOpenInventorFactory.Create, IPresentation.Text and IObservableElementEnumerable.GetEnumerator. For a plug-in which has its own custom data source, a workaround for this can be to move the initialization code to the implementation of IDataSource.Open or IDataSource.Resolve. The Ocean for Petrel API is functional in the latter, but not in the first. In all Petrel versions up to and including Petrel 2009.2 an Ocean module could add a custom data source ( IDataSource instance) to the global data non serializable source manager in a handler of the WorkspaceOpened event and add Identifyable objects from that data source to Petrel. The droids of these objects then were correctly resolved when the project was reloaded. However this made it impossible to resolve droids in a reference project and adding a non serializable data source in this way must be considered a bug. With Petrel 2010 it is no longer possible to both add a non serializable data source in a handler of the WorkspaceOpened event and have the droids be resolved at the same time. With Petrel 2010 data sources should be added to the system indirectly by registering a DataSourceFactory. A data source which is added this way is opened early and this restricts what can be done in the IDataSource.Open. Petrel doesn‟t support License Borrowing, and there will be issues starting Petrel with expired borrowed plug-in licenses. It is therefore strongly discouraged to do License Borrowing for plug-ins. Custom Domain Objects cannot be copied (via copy-paste) to a HorizonInterpretation. If the PillarGridPlayer toolbar is visible and the Petrel end user activates an Ocean process that does not explicitly set the toolbar to visible, the toolbar will disappear until another process is activated. The Ocean Core and Services Coordinates service erroneously selects a datum transform (sometimes randomly from among several compatible transforms) when asked to create a conversion operation between two late bound CRSs based on different datums. In this case, the service should refuse to create an operation unless the caller explicitly specifies the datum transform. The service will be changed in the
Known Issues in Ocean for Petrel 2010.1 2011 timeframe to behave that way. To protect against this future behavior change, plug-ins should always specify the transform explicitly. Petrel ships with a Coordinate System Catalog that includes CRSs from several authorities: EPSG, ESRI, SIS, and SLB. When Petrel is started, only the EPSG and ERSI CRSs are loaded into the Coordinates service by default. The SIS and SLB systems are only loaded when the Petrel end-user opens the CRS selection dialog (in Project Settings). If a plug-in requests a CRS using a SIS or SLB code before the end-user has opened the selection dialog, the request will fail – even if it exists in the catalog. The workaround is for the developer to find the WKT for the desired SLB or SIS CRS using the Coordinate System Manager utility and request the CRS by WKT rather than by code. It is not possible to use a custom FileFormat to import/export spatially-enabled native Petrel domain objects to/from a project with a non-NULL CRS. The property SegmentationSpec.MaxInclinationChange had incorrect unit conversion prior to 2010.1. The behavior of this API has changed to correctly use radians (SI). Please make sure this change is handled correctly in your application.
Error! Reference source not found.
New features in Ocean for Petrel 2009.2 Domain API Reservoir Engineering – Plug-in Simulator Support to copy custom simulation cases Namespace: Slb.Ocean.Petrel.Simulation.EclipseFormatSimulator.CaseManipulationH andler.PostCopy The new API provides a method for a post copy operation that allows custom simulation cases to do the necessary work to allow their simulation case to participate in copy and paste workflows.
Access to the simulation case version Namespace: Slb.Ocean.Petrel.Simulation.ISimulationManager.GetSimulatorVersion The new API provides access to the simulator version field of the simulation case.
Support to modify the restart time of a simulation case Namespace: Slb.Ocean.Petrel.Simulation.EclipseFormatSimulator.CaseManipulationH andler.GetRestartDates The new API provides a method that is called during the restart case insert process. The plug-in simulator can then manipulate the expected restart time steps based on the original one.
Support to rename a simulation case Namespace: Slb.Ocean.Petrel.Simulation.EclipseFormatSimulator.CaseManipulationH andler.PostRename
Error! Reference source not found. The new API provides a method for a post rename operation that allows custom simulation cases to do the necessary work to allow their simulation case to be renamed. Please note that this method will only be called on a successful Petrel Case rename.
Seismic Domain Updates to Fault Interpretation Polyline Access Namespace: Slb.Ocean.Petrel.DomainObject.Seismic.FaultInterpretation The API has been updated to allow API users to access fault interpretation polylines with or without seismic context. The API has been updated to as follows: Obsoleted Method s:
public void SetPolylines(IEnumerable polylines) public IEnumerable GetPolylines(SeismicLine2D seismicLine) public IEnumerable GetPolylines(SeismicCube seismicCube) public void SetPolylines(SeismicLine2D seismicLine, IEnumerable polylines) public void SetPolylines(SeismicCube seismicCube, IEnumerable polylines) Note: The above methods are deprecated and not fixed (see SMR:2358805) New Method s
public void SetPolylines ( IEnumerable polylines) public IEnumerable GetPolylines() Users will need to use the new API to edit and access the seismic context of the fault interpretation, meaning that Ocean plug-ins need to be modified for 2009.2.
Pillar Grid Contacts Visible in Petrel Editor Namespace: Slb.Ocean.Petrel.DomainObject.PillarGrid.Contact This API provides the following capabilities: 1. Ability to create Contact via Ocean for Petrel API and set a flag on the Contact to indicate if all zones or all segments have the same constant value. 2. Ability to create a Contact via Ocean for Petrel and set a constant value on the Contact [SetZValue(Zone, Segment, double) or SetZValue(Zone, double)] and to view/edit this contact in the 'make contact' process. (Also need SetZValue(Segment, double), SetZValue(double)) 3. A behavior such that after a creation of Contact via Ocean API and setting the value on Contact via the fine level API [ SetZValue(Zone, Index2, Corner, double)], this 'fine level' contact cannot be viewed/edited by the ' make contact' process, and if I apply this process on its parent ContactSet, this Contact will lost.
Error! Reference source not found.
Visualization OpenInventor Node interaction detail Namespace: Slb.Ocean.Petrel.UI.Window3DPickedPoint.PickDetails Ocean provides an OpenInventor SoPickedPoint object describing the pick in the scenegraph. This object can be queried for more detailed pick information such as the SoDetail of the picked node in the OpenInventor scenegraph.
Other New Command Line Options (-exec) Petrel's command line now has a "-exec" option to execute a custom method requiring no user interaction. All Ocean API can be used in "-exec" mode. Particularly, some API can only be used when the "-exec" option is specified in the command line. These API exclusive to the "-exec" mode are: - PetrelProject.NewProject - PetrelProject.LoadProject - PetrelProject.SaveProject - PetrelProject.SaveProjectAs Typical "-exec" option usages include: - using Petrel data, - performing computations, - fetching data from other sources, - storing data in Petrel. Syntax of the "-exec" option: petrel.exe -exec assemblyQualifiedTypeName methodName [projectName] The command line parameters are: - assemblyQualifiedTypeName: Assembly qualified name of the class containing the method to be executed. - methodName: Name of the custom method to be executed. - projectName: Name of the project to be opened. This parameter is optional. BUT the "-licensePackage" option should be specified at the same time. Otherwise, the custom method can only execute if there is user interaction to manually select the license package. Please refer to the Petrel.chm help manual for more information about other Petrel command line options, and the white paper “Petrel Command Line Exec Option” in the Ocean for Petrel chm.
New features in Ocean for Petrel 2009.1
New features in Ocean for Petrel 2009.1 Domain API Reservoir Engineering – Plug-in Simulator UI extensibility for simulator plug-ins Namespace: Slb.Ocean.Petrel.Simulation.SimulatorPageUIFactory, Slb.Ocean.Petrel.Simulation.SimulatorPageLogic MySimPage : SimulatorPageLogic PageList.Add(new MySimPage()) MySimPageFact : SimulatorPageUIFactory CoreSystem.Services.AddService(typeof(TArgPack), MySimPageFact.ServiceType, new MySimPageFact())
For more detailed information, please consult section “Error! Reference source not found.” on page Error! Bookmark not defined..
Programmatically run a simulation case Namespace: Slb.Ocean.Petrel.Simulation. This feature allows to programmatically execute the same operations a Petrel user can trigger by clicking the Run button on the Define simulation case process dialog. How to use the API: 1. Define the class that will run simulation 2. Derive custom CaseRunnerMonitor class. (Optional. But necessary when user wants to capture the finish events from Simulation process) 3. Get an instance of CaseRunner through PetrelSystem.SimulationManager, and run the Simulation. Simulation.CaseRunner.Export() Simulation.CaseRunner.Run() Simulation.CaseRunnerMonitor.RunAborted() Simulation.CaseRunnerMonitor.RunCompleted()
New property to access exported sections of an Eclipse Deck The EclipseFormatSimulator provides a new property RequestedExportSections to specify which sections of the Deck need to be exported when Petrel does the export.
New features in Ocean for Petrel 2009.1
Interface to use keywords of an Eclipse Deck Namespace: Slb.Ocean.Petrel.Simulation The API allows accessing the individual sections of an Eclipse deck such as GRID, SCHEDULE etc. to add, insert or remove keywords from each section. It is possible to get an EclipseKeywordEditor from ISimulationManager by passing the relevent Simulation domain object. Then the KeywordDeckSections object allows access to a desired section. The API provides access to a Keywords IEnumerable and CreateKeyword() methods to create and edit keywords. EclipseKeywordEditor EclipseKeywordSection.CreateKeyword(…)
Access to segmentation borehole‟s flow paths Namespace: Slb.Ocean.Petrel.DomainObject.Simulation.SimulationRoot The multi-segmented well model in Petrel and ECLIPSE divides the whole well bore into segments with different physical properties to allow ECLIPSE to accurately model the fluid physics throughout the well bore. The SegmentationSpec object represents the segmentation of a borehole‟s flow paths. The API allows creating and accessing SegmentationSpec. SimulationRoot.SegmentationSpecCollection Simulation.SegmentationSpec.Spec .SegmentLength .UseFriction
Simulation case $variables ISimulationManager.GetCaseVariables(…)
Liners (completions type) Namespace: Slb.Ocean.Petrel.DomainObject.Well.Completion The type LinerString is added to the Completions API and can be created via Borehole.Completions.CreateLinerString. In previous versions liners had to be modeled as CasingString instances with the StartMD set greater than zero, and as such would show in the Petrel UI with the casing icon rather than the liner icon.
New features in Ocean for Petrel 2009.1
Uncertainty Workflow API Namespace: Slb.Ocean.Petrel.Uncertainty The Uncertainty API enables extensibility of the Petrel Uncertainty process. This is done by registering user-defined algorithms via PetrelSystem.UncertaintyManager. The benefit is that the algorithm may focus directly on the parameter tuning of the optimization loop, and can leave to Petrel the logistics and machinery of updating models, re-gridding, creating simulation decks and running the simulation. For more detailed information, please consult section “Error! Reference source not found.” on page Error! Bookmark not defined.. Distribution functions A distribution exposes an operation over an argument package containing all the distribution settings. Custom distribution functions MyDistr : Distribution.NextSample(…)
Sampler Provides parameter values to the Uncertainty process. This can be either random values (e.g. Monte-Carlo sampling) or following some sort of methodology (e.g. experimental design). Custom samplers MySampler : Sampler.Validate(…) .CreateExecutor(…)
SamplerExecutor.SampleValues(k,output)
Proxy (Emulator) Computes an approximation to simulation output. Usually, an emulator is calibrated with a small number of actual simulations before it can provide approximated results (e.g. neural network). Custom simulator proxies MyProxy : Proxy.CreateExecutor(…) et c.
ProxyExecutor.Evaluate(input,output)
Optimizer Finds an optimal set of control parameters of a given objective. This usually involves evaluation of the simulator for a large number of input configurations Custom optimizers MyOpt : Optimizer.CreateExecutor(…) etc. OptimizerExecutor.SampleValues(k,output) OptimizerExecutor.ReportOptimums(…)
New features in Ocean for Petrel 2009.1
Data Analysis Selection Filters Namespace: Slb.Ocean.Petrel.DomainObject.Analysis A LogicalFilter is defined by an association of logical operation on the result of other filters. A PropertyVersionFilter is defined by an association of regions in the property space [FirstProperty, SecondProperty], each region including or excluding a range of values (1D filters) or a set of points (2D filters). The DataSelectionFilterRoot allows getting PropertyVersionFilter and LogicalFilter objects in the context of a Project.A DataSelectionFilterRegion is defining a set of values or points to be included by a PropertyVersionFilter object. SelectionFilterRegion can define a 2D or 1D region: a 2D region will be represented by a polygon, whereas a 1D region will be a value range with a lower and upper limit. 1D property (selection) filters DataSelectionFilterRoot.CreatePropertyDataFilter() PropertyDataFilter1D.Add/Get/Set/RemoveRegion() PropertyDataFilter1D.Property PropertyDataFilter1D.IsIncluded(...) myWindow.SetVisible(PropertyDataFilter1D/2D)
Variogram Domain Object Namespace: Slb.Ocean.Petrel.DomainObject.PillarGrid A variogram describes the natural variation in a property (surface property, model property, etc.) and is used as input to both discrete and continuous property modeling. The Ocean for Petrel API exposes the Petrel model variogram defined in the Property modelling -> Data Analysis process, from the Variograms tab. The PillarGrid.DataAnalysis is used to create and get PillarGrid.ModelVariogram and PillarGrid.DictionaryModelVariogram instances. In addition to a continuous property, a model variogram instance will have associations with a PillarGrid.Zone or with all zones. In addition to a dictionary property, a DictionaryModelVariogram instance will have associations with one or all PillarGrid.Zone and facies. DataAnalysis.Create/Get…(…) Grid.DataAnalysis.Create/Get…(…)
New features in Ocean for Petrel 2009.1 etc. PillarGrid.DictionaryModelVariogram …
Correlation data (cross plot) Domain Object Namespace: Slb.Ocean.Petrel.DomainObject.Analysis Ocean for Petrel 2009.2 exposes the cross plot domain object, used in property modeling in Petrel. A crossplot domain object describes a bivariate distribution. The bivariate distribution values are contained in a collection of Point2 values. CorrelationData2D[k].X/Y
Function Domain Object Namespace: Slb.Ocean.Petrel.DomainObject. Analysis Ocean for Petrel 2009.2 exposes the function domain object, used in property modeling in Petrel. This requirement relates to the f unction domain object, not the function window/renderer. A Function domain object describes a linear regression function. The data are contained in a collection of Point2 values. Function[k].X/Y
LaunchDataAnalysisDialog Namespace: Slb.Ocean.Petrel.PetrelSystem.ProcessDiagram Programmatically launch the data analysis tool / dialog of Petrel ProcessDiagram.ShowDataAnalysisProcess(…)
New features in Ocean for Petrel 2009.1
Seismic Performance Improved bulk access speed Namespace: Slb.Ocean.Petrel.DomainObject.Seismic Performances of access to seismic data have been improved. Both ISubCube and ITrace access have been optimized and should now be limited by the disk access. No API change. On a default developer machine, initial measurements show the following performance improvements: ~28MB/s to 180MB/s for 32-bit data sample by sample access (fully cached) ~24MB/s to 120MB/s for 8-bit data sample by sample access (fully cached, slower due to byte to float conversion) ~60MB/s to 260MB/s for 32-bit data using the ToArray () (fully cached) ~60MB/s to 270MB/s for 8-bit data sample by sample access (fully cached) For large cubes, the machine yields a sustained throughput of 70MB/s or so fr om disk. (Note that these numbers are measured for a best-case scenario, where the cube is accessed in the most efficient way: access has been designed to minimize cache misses, looping through all samples in each 64x64x64 brick in the zgy file).
Regular Height Fields Surface Performance Improvement Namespace: DomainObject.Shapes A new method: SurfaceProperty.SetRecordValues(…) has been implemented to set Surface properties in a bulk fashion. Performances using this method are much better than the random access.
Multi-Threading - Attribute computation Namespace: Slb.Ocean.Petrel.SeismicAttribute This requirement was already available in Ocean for Petrel 2008.1 with the new IAttributeVersion2 interface. It now supports multiple seismic cubes and additional testing has been provided for 2009.2. The interface IAttributeVersion2 inherits Iattribute, it influences performance, threading, API access and persistence. Performance: The generator's Calculate method is now called with subcubes tailored to what is required to fulfill the user interaction that caused the computation. For example visualization of a horizontal slice triggers thin subcubes to be p assed for calculation. The original IAttribute always got called with sub cubes of one seismic trace. IAttributeVersion2 uses a more optimized code path to provide improvement in computation speed of around an order of magnitude for simple algorithms. With complex algorithm the performance improvement might not be as noticeable. IAttributeVersion2 implementations with large computational footprints run faster because they are called fewer times than before (with larger subcubes). Threading and API access: IAttributeVersion2 computes in one of two thread modes: SingleWorkerThread or MultipleWorkerThreads.
New features in Ocean for Petrel 2009.1 SingleWorkerThread means computation is carried out in one single thread which is not the main (UI) thread. Only a small cross-thread-safe subset of the Ocean for Petrel API is available, only the „reading‟ part of the Domain API can be used. Any code path which changes data up in the GUI (forms) technology will throw an exception as it is considered an illegal cross thread operation. MultipleWorkerThreads means the calculate method is called in parallel on several threads (possibly one to four). The generator implementation must use only thread safe (.Net) components in its implementation, and cannot use any Ocean resources (like domain objects). Persistence IAttributeVersion2 can optionally be persisted (if it is serializable). This will in effect make it a singleton and just its identity will be persisted. Any state should be persisted with the argument package. Note that it is recommended to implement your own serialization logic rather than using .NET Serialization. The generator of a IAttributeVersion2 is *not* persisted. This was mandatory with the old version.
Multi-Threading - Generic seismic bulk access Namespace: Slb.Ocean.Petrel.DomainObject.Seismic The IAsyncSubCube GetAsyncSubCube(…) method provides random asynchronous read and write access to the data. The implementation is not thread safe, but multiple sub cubes can be processed in parallel in separate threads. The GetAsyncSubCube can only be called in the main thread, but the returned handle can be used in any thread. Instances of ISubCube must not be used in the main thread when there are active IAsyncSubCube instances. In the main thread: IAsyncSubCube subCubeIn = cubeIn.GetAsyncSubCube(...); IAsyncSubCube subCubeOut = cubeOut.GetAsyncSubCube(...); In a worker thread: foreach (Index3 index in subCubeOut) { subCubeOut[index] = subCubeIn[index]; } subCubeIn.Dispose(); subCubeOut.Dispose();
New features in Ocean for Petrel 2009.1
Seismic Domain Fault (Ant Tracking) patches Namespace: Ocean.Petrel.DomainObject.Seismic.FaultPatchSet FaultPatchSet represents a set of fault surfaces, whose geometry is a set of indexed triangles, with properties attached to each fault. A fault patch is an individual Fault in a FaultPatchSet object. This fault is usually computed from seismic data and requires a seismic survey definition on creation, vertices are snapped to the nearest index position.
Fracture patches Namespace: Ocean.Petrel.DomainObject.Shapes.FractureNetwork FractureNetwork represents a Petrel fracture network with properties. Individual fractures are represented by the FracturePatch object, and can be accessed through FractureNetwork.FracturePatches and FractureNetwork.PatchAtIndex. A FracturePatch is an individual Fracture in a FractureNetwork object. The fracture can be expressed as a triangulated surface, through IndexedTriangleMesh.
Multiple input seismic attributes Namespace: Slb.Ocean.Petrel.SeismicAttribute.IAttribute Ocean for Petrel now supports multiple seismic input cubes. The API is unchanged, but now the Slb.Ocean.Petrel.SeismicAttribute.IAttribute.NumInputs can be greater than 1.
Data Management Reference project tool awareness and Copy/Paste of Custom domain objects Namespace: Slb.Ocean.Petrel.Basics.ICopyable Slb.Ocean.Petrel.Basics.ISyncable The API allows custom domain objects or extensions to native domain objects to do t he roundtrip between an opened Petrel project and a reference project using the Reference Project Tool and to participate in copy-paste actions in Petrel, including cascading copies. ICopyable to handle duplication IPropertyComparable to provide object-to-object comparisons of e.g. identity or version IObservableElementCollection, IObservableElementCollectionFactory, IObservableElementEnumerable, IObservableElementEnumerableFactory
to allow handling of children items in a custom domain object Custom Extensions can be managed using the IO.AttributeContainer IO.ICustomAttributeService
New features in Ocean for Petrel 2009.1
SurfaceAsIExtensionSource Namespace: Slb.Ocean.Petrel.DomainObject.Shapes RegularHeightFieldSurface implements IExtensionSource, so it can be extended with custom extensions.
WellMarkersIIdentifiable Namespace: Slb.Ocean.Petrel.DomainObject.Well.Marker Well markers are now IIdentifiable enabling data management solutions.
Data Fidelity: Attributes of Petrel Domain Objects The API now provides access to native (WellKnown) attributes – attributes with ”special meaning”. Each attribute is identifiable and String, Boolean and DateTime properties are now supported.
Surfaces/horizons Surface.GetWellKnownProperty() Surface.Properties WellKnownSurfacePropertyTypes.Velocity etc. SurfaceProperty.IsGeometryProperty HorizonProperty2D/3D.IsGeometryProperty
Point sets PointSet.Create/GetWellKnown[Dictionary]Property() WellKnownPointSetPropertyTypes.DipAzimuth etc. PointProperty.IsGeometryProperty
Boreholes BoreholePropertyCollection Borehole.PropertyAccess.Get/SetPropertyValue() WellKnownBoreholePropertyTypes.SpudDate etc.
Point well data General: WellPointPropertyCollection
Well markers Marker.PropertyAccess.Get/SetPropertyValue() WellKnownMarkerPropertyTypes.Interpreter etc.
Checkshots WellKnownBoreholePropertyTypes.TWTPicked etc. CheckShot.GetPropertyAccess()
Point well logs PointWellLog.GetPropertyAccess() WellKnownPointWellLogPropertyTypes.MD etc.
New features in Ocean for Petrel 2009.1
UI and Look & Feel Interaction Events Extension Namespace: Slb.Ocean.Petrel.UI.WindowMode Provides extensions in the interaction events to cater for keyboard events. WindowMode.OnKeyDown() WindowMode.OnKeyUp()
Toolbars and Tools associated with a Process Namespace: Slb.Ocean.Petrel.Workflow.Process, Slb.Ocean.Petrel.UI.Tools.WellKnownTools The new ToolbarsCore and ToolsCore properties are called by the framework whenever it needs to know respectively the list of PetrelToolbars and PetrelTools associated with a Process. An implementation of this method typically returns different PetrelToolbar or PetrelTool configurations based on e.g. the active IToggleWindow. UI.WellknownWindowModes Process.Tool[bar]sCore
Process Insensitive Namespace: Slb.Ocean.Petrel.Workflow.Process Enables Ocean for Petrel processes to be set as disabled (grayed out) if e.g. a license can not be obtained or if the required input data isn‟t present. Process.Enabled = true/false Process.EnabledChanged/OnEnabledChanged() event
Custom windows tree extensions for Petrel windows Namespace: Slb.Ocean.Petrel.Basics.IExtensionsSource Native Petrel window interfaces (IWindow3D, IMapWindow, IWellSectionWindow, IIntersectionWindow, IFunctionWindow) now extend Slb.Ocean.Petrel.Basics.IExtensionsSource, giving them an Extensions property. Like other native domain objects, this allows Ocean for Petrel applications to add and remove custom domain objects as children of the trees in the Petrel tree hierarchy.
AutoLegendProgrammaticShowHide Namespace: Slb.Ocean.Petrel.UI.IWindow3D Support for programmatically showing/hiding Petrel‟s AutoLegend bool IWindow3D.ShowAutoLegend
New features in Ocean for Petrel 2009.1
Cursor tracking independent of IToggleWindow, with proper domain handling Namespace: Slb.Ocean.Petrel.UI.IWorldCursor The new World Cursor API allows applications to participate in cursor tracking without explicitly needing to implement a custom toggle window. UI.IWorldCursor
Petrel Task Manager Namespace: Slb.Ocean.Petrel The PetrelLogger.NewAsyncProgress(..) allows displaying progress of separate-threaded processes in the Petrel task manager. using (IProgress pr = PetrelLogger.NewAsyncProgress( "test", ProgressType.Cancelable)) { for (int i = 0; i < 100; i++) { pr.ProgressStatus = i; } }
Namespace: Slb.Ocean.Petrel.IO It is now possible to programmatically launch an import or export dialog. IFileFormatCollection.ShowExportDialog(fmt,path,...) IFileFormatCollection.ShowImportDialog(fmt,path,...)
Select active explorer tree Namespace: Slb.Ocean.Petrel.PetrelProject Gets or sets the active tree in Petrel explorer. PetrelProject.ActiveTree = PetrelProject.Models
New features in Ocean for Petrel 2009.1
Expand/collapse branches in the explorer trees Namespace: Slb.Ocean.Petrel.PetrelProject Enable programmatic expansion of data tree nodes PetrelProject.TreeOperations.SetExpanded(obj, TreeElementState.Expanded)
Workflow editor folders Namespace: Slb.Ocean.Petrel.Workflow.IWorkflowEditor Provides a mechanism to place a workstep under a given workstep folder (in the workflow editor). IWorkflowEditor.Add(wkstp,wkstpGroup)
Provides a mechanism to add new folders f or worksteps in the workflow editor Processes.FindOrCreateWorkstepGroup("My new folder")
Infragistics dependencies have been removed Namespace: Slb.Ocean.Petrel.PetrelSystem, Slb.Ocean.Petrel.UI.Tools.IToolService Infragistics dependencies have been removed from the Ocean for Petrel API. A new PetrelSystem.ToolService can be used to Create new toolbars/access native Petrel toolbars Create new menus/access native Petrel menus Register context menu handlers Add tools to toolbars, menus
Template Hierarchy Namespace: Slb.Ocean.Petrel.UI.DictionaryColorTableEntry The Slb.Ocean.Petrel.UI.DictionaryColorTableEntry class now has a Parent property to support hierarchies.
Retrieving Measurement for its name NameSpace: Ocean.Petrel.PetrelUnitSystem a new method has been added to get the measurement from a measurement name: public static IUnitMeasurement GetUnitMeasurement(string unitMeasurementName)
New features in Ocean for Petrel 2009.1 Other Development A document describing Module Deployment Best Practices has been released recently and is available from the Ocean Portal: Developer Center > Best Practices > Module Deployment. The Ocean for Petrel 2009.1 SDK now installs even if a previous version (Ocean for Petrel 2008.1 SDK) is installed. It allows keeping the documentation of previous Ocean for Petrel SDK releases. 64bits support: The Ocean for Petrel 2009.1 SDK supports Petrel 2009.1 x32 on Windows XP32 and XP64, and Petrel 2009.1 x64 on Windows Vista 64 Ocean for Petrel Wizards The wizards now install on top of Visual Studio 2005 and Visual Studio 2008. It is now possible to create projects targeting Petrel 2008 or Petrel 2009 (if installed on the computer). The installer wizard allows choosing the targeted version of Petrel: Petrel 2008, Petrel 2009 x32 or Petrel 2009 64 bits (providing warnings in case of incompatibilities).
Installation and Un-installation To improve the Petrel awareness of plug-ins installed we have developed new Ocean for Petrel plug-in install and uninstall procedures. This is mainly to help the Petrel and plug-ins un-installation. When a plug-in is installed on top of Petrel it registers itself to inform Petrel it exists, then as Petrel knows which plug-ins are installed on top of itself it can, when it is uninstalled, selectively un-install (or not) these plug-ins. When Petrel is uninstalled it checks if plug-ins are installed and asks the user if and which plug-ins need to be un-installed. In case t he user wants to uninstall plug-ins the Petrel uninstaller gets the list of registered plug-ins for Petrel and asks the user which registered plug-ins should be uninstalled. It then launches successively the uninstaller of all selected plug-ins (using the option to not check for dependencies). Petrel un-installation needs to be restarted manually then
Appendix A
Appendix A: Migration to Simulation Results on the Petrel Results Tree Introduction In Petrel 2010 the simulation results have been moved from the Models tree to the Results tree. This document details issues an Ocean client may face due to this change and suggests potential ways to solve those issues.
Petrel Simulation Results When the user opens an older project in Petrel 2010 the simulation results on the Models tree will be automatically converted to results on the Results tree. An example of the results on Petrel 2009 is shown below:
An example of the same result on Petrel 2010 is shown below:
Appendix A
Important differences to note: In the Petrel 2009 version the user can simply select the data they are interested in directly from the models tree (here t he water saturation for Case HOR-1STD_ECLIPSE_100). In Petrel 2010 the user must select the simulation from the Cases tree and then the identifier of the result they are interested in from the Results tree. Individual time steps can be selected by the user in the Petrel 2009 version. In Petrel 2010 the individual time steps are not selectable and the user must use the timeplayer.
Issues you may face Drop target In previous versions of Ocean and Petrel, you could create a drop target on your dialog and simply drop in the property you wished. In version 2010 you will no longer be able to do this as that property will no longer be selectable in the Models tree and will not be displayed in the same manner in the Results tree.
Appendix A There is no direct equivalent and instead, to achieve the same behavior, you would have to provide the Case, the GridResult type and a timestep. You can then use the Ocean API to retrieve the property data. The image below shows a possible solution whereby the user may drop a case and the GridResult (in this case „Water saturation‟). Your Ocean plug-in can then retrieve a list of all timesteps and populate the combo box as shown with those timesteps. The user can then select the timestep of interest.
Appendix A The following are some code snippets of how you could achieve this:
Case Droptarget private void dropCase_DragDrop( object sender, DragEventArgs e) { Case c = e.Data.GetData( typeof(Case)) as Case; if (c != null) { textCase.Text = c.Name; textCase.Tag = c; RefreshTimesteps(); } }
Updating of the timesteps Combo box private void RefreshTimesteps() { comboTimesteps.Items.Clear();
// comboTimesteps is the timesteps Combo box
Case c = textCase.Tag as Case; if (c != null) { GridResult gr = textResult.Tag as GridResult ; if (gr != null) { GridPropertyTimeSeries gpts = c.Results.GetGridPropertyTimeSeries(gr); textGrid.Text = gpts.Grid.Name; // textGrid is the Grid text box if (gpts.IsGood) { if (gpts.SampleCount > 0) { foreach (DateTime dt in gpts.TimeSamples) comboTimesteps.Items.Add(dt); comboTimesteps.SelectedIndex = 0; comboTimesteps.Enabled = true; return; } } PetrelLogger .WarnStatus( string.Format( "Case '{0}' does not have results for '{1}'.", c.Name, gr.Name)); } } comboTimesteps.Enabled = false; return; }
Appendix A
Retrieval of the property private void PrintGridProperty( Case c, GridResult gr, DateTime timestep) { GridPropertyTimeSeries gpts = c.Results.GetGridPropertyTimeSeries(gr); if (gpts.IsGood) { GridProperty gp = gpts[timestep]; Index3 num = gp.NumCellsIJK; PetrelLogger .InfoOutputWindow( String.Format( "Printing property '{0}' value at '{1}'.", gp.Name, gp.Date)); for (int i = 0; i < num.I; ++i) { for (int j = 0; j < num.J; ++j) { for (int k = 0; k < num.K; ++k) { PetrelLogger .InfoOutputWindow( String.Format( "{0} [i {1}, j {1}, k {3}] at {4} => {5}" , gp.Name, i, j, k, gp.Date, gp[i, j, k])); } } } return; } }
Sample Output Water Water Water Water Water Water Water Water
Pushing back properties to the „Models‟ tree For your workflow it may make sense to push back properties from the Results tree to the Models tree. Please note that there would be some issues with this approach in that these „Models‟ tree results would not be updated on a subsequent simulation run (you would need to push them back again). In addition this would also require more resources and memory to effectively duplicate the properties. Thus this approach is only recommended as an interim solution until you have migrated fully to the new Results tree based API. Here is a sample routine for pushing back 3D grid properties to the „Models‟ tree: void pushBackGridResultForAllTimeSteps (Case c, GridResult gr) { if (c == null || gr == null) return; GridPropertyTimeSeries gpts = c.Results.GetGridPropertyTimeSeries (gr); if (gpts.IsGood) { PropertyCollection pc = gpts.Grid.PropertyCollection ; using (ITransaction trn = DataManager .NewTransaction ()) { trn.Lock(pc); foreach (GridProperty gp in gpts.Samples) { Index3 num = gp.NumCellsIJK ; using (IProgress x =
Appendix A PetrelLogger .NewProgress (0, num.I * num.J)) { x.SetProgressText ( String.Format( "Copying property '{0}' at '{1}' to grid '{2}'." , gp.Name, gp.Date, gp.Grid.Name ) ); Property p = pc.CreateProperty (gr.PropertyVersion ); p.Name = gp.Name; p.UseDate = true; p.Date = gp.Date; for (int i = 0; i < num.I; ++i) { for (int j = 0; j < num.J; ++j) { x.ProgressStatus = i * num.J + j; for (int k = 0; k < num.K; ++k) p[i, j, k] = gp[i, j, k]; } } } } trn.Commit(); } PetrelLogger .Status("Finished copying properties." ); } }
Here is another routine for pushing back grid property for a specific time step value: void pushBackGridResultForTimeStep (Case c, GridResult gr, DateTime ts) { if (c == null || gr == null) return; GridPropertyTimeSeries gpts = c.Results.GetGridPropertyTimeSeries (gr); if (gpts.IsGood) { PropertyCollection pc = gpts.Grid.PropertyCollection ; using (ITransaction trn = DataManager .NewTransaction ()) { trn.Lock(pcr); GridProperty gp = gpts[ts]; Index3 num = gp.NumCellsIJK ; using (IProgress x = PetrelLogger .NewProgress (0, num.I * num.J)) { x.SetProgressText ( String.Format( "Copying property '{0}' at '{1}' to grid '{2}'." , gp.Name, gp.Date, gp.Grid.Name ) ); Property p = pc.CreateProperty (gr.PropertyVersion ); p.Name = gp.Name; p.UseDate = true; p.Date = gp.Date; for (int i = 0; i < num.I; ++i) { for (int j = 0; j < num.J; ++j) { x.ProgressStatus = i * num.J + j; for (int k = 0; k < num.K; ++k) p[i, j, k] = gp[i, j, k]; } } }
DROID issues If in your Ocean plug-in you have saved a DROID for a property that has moved from the Models tree to the Results tree, then unfortunately that DROID will not be resolvable. In the code snippet shown below DataManager.Resolve() would return null. Please note that no exception would be thrown here. // A droid for a Property that has moved from the 'Models' tree to // the 'Results' tree will not be resolvable. // The following will return null. Property resolvedProperty = DataManager .Resolve(droid) as Property ;
If you have a workstep in which you displayed a drop target for that property, then as you would be unable to resolve that DROID then you would thus be unable to show the property in that drop target. For the scenario where you have used the default grid control for a workstep (i.e. where you have not made a custom UI) then again those drop targets would be empty as the DROID would not be resolvable. The Ocean team would be interested in receiving feedback from clients who feel that t his would present a problem for them. If you have a use case that involves resolving a DROID for a moved property then please contact the Ocean Product Champion and provide details.
Appendix B
Appendix B: Use of IObservableElementEnumerable instead of INotifyingEnumerable From Ocean for Petrel 2010.1 Slb.Ocean.Basics.INotifyingEnumerable is obsoleted. Please use IObservableElementEnumerable instead of INotifyingEnumerable. The factory for it (INotifyingEnumerableFactory) was made obsolete in Ocean for Petrel 2009.1. This new interface allows a plug-in to notify Petrel that multiple elements have been added or removed by raising the EnumerableChanged event only once. The code fragment below shows how the new interface can be implemented: using System.Collections; using System.Collections.Generic; using Slb.Ocean.Petrel.Basics; public class Folder : IObservableElementEnumerable { List