Release Notes Version 1#

What’s new in Blueback Python Tool Pro 1.3#

Python Tool Pro 1.3.0 is a minor release with added functionalities around well survey objects and performance improvements when working with grid properties.

New features#

Get parent well from well_survey#

The PTP Python API was updated to include the property .well on well_survey objects. This enables users to retrieve the parent well from the well_survey object.

Get well surveys from well object#

It is now possible to get an iterator of all well surveys in a well object. Use the property well.surveys to retrieve this.

Changed features#

Verification of SSL certificate#

After the expiry of the Let’s Encrypt DST Root CA X3 on 31st of September 2021, some users experienced issues with the authentication process. A change in requesting the access token from Keystone resolves this issue. This change does not affect the users directly.

Improvements on retrieving grid properties#

Major improvements were achieved on performance for retrieving grid properties and setting values in the Petrel object.

Deleted features#

No features were deleted in Blueback Python Tool Pro.

What’s new in Blueback Python Tool Pro 1.2#

New features#

Introduction of experimental methods#

Blueback Python Tool Pro introduces the concept of experimental methods. These are methods for which the API is not finalized yet and might be changed or removed in later releases. Users of Blueback Python Tool Pro must explicitly enable experimental methods in the Petrel connection to be able to use them. The following methods or Petrel domain objects are classified as experimental: * Workflows * ijks_to_positions(), positions_to_ijks() * md_to_xydepth(), md_to_xytime() * append_scriptname_to_history()

Update and retrieve history from Petrel objects#

The history of Petrel domain objects changed by Blueback Python Tool Pro is updated with an entry that it was edited by Blueback Python Tool Pro and which method was used.

The automatic history update can be disabled in the PetrelConnection at the start of your Python code.

The method retrieve_history() enables users to retrieve the Petrel history as a Pandas DataFrame for any supported domain object.


Blueback Python Tool Pro enables the users to retrieve Petrel workflows and execute them from an external Python IDE. Users can access input and output variables from Python Tool Pro and assign data objects retrieved from Petrel.

ijks_to_positions(), positions_to_ijks()#

Using a list of ijk indices, it is now possible to retrieve a list of xy and time/depth values. Equally it is possible to retrieve a list of ijk indices from a list of xy and time/depth values. Methods are available for model grids, horizon interpretation 3ds, horizon properties, seismic cubes, and surfaces.

md_to_xydepth(), md_to_xytime()#

Using a list of measured depths, it is now possible to retrieve a list of xy and time/depth values for a well.


By using the method append_scriptname_to_history() on a PetrelConnection class it is possible to add the Python script file path to the Petrel history of data objects updated with Blueback Python Tool Pro.

Changed features#

Use Pandas DataFrame in set() method#

It is now possible to update values of Petrel domain objects: surface attributes, discrete surface attributes, horizon interpretation 3ds, horizon properties, and 2d seismic using a Pandas DataFrame as an input to the set() method.

Port number can be read from a file#

Blueback Python Tool Pro creates a file called “session” with the port number in the users AppData (C:Users{username}AppDataLocal.cegalprizm.pythontoolpro) on Petrel start-up. The Python Tool Pro attempts to read this file to establish the Petrel connection. Only the last Petrel instance will be saved in the ‘session’ file. The port number can still be defined in the PetrelConnection(portnumber=40129), which overwrites the port number in the session file.

Deleted features#

Memory mapping#

Memory mapping has been disabled for transfer of data between Petrel and Python Tool Pro client. All data is streamed now.

Bug fixes#

  • Performance improvements - Major performance improvements were achieved in iterating over many Petrel objects in Blueback Python Tool Pro. The methods wells(), well_logs(), and discrete_well_logs() of a PetrelConnection class complete in a fraction of a time compared to previous versions.

  • #43866 The log() method accepts not existing wells and does not work for a well in the subfolder -

The log() method on global well log and discrete global well log now raises PythonToolException when the supplied well does not exist in Petrel project. The log() method now also successfully retrieves logs from wells in a subfolder.

  • #43039 2D line chunk get_rawvalues() and as_dataframe() raises ValueError for lines with no. samples over 407 -

Methods get_rawvalues() and as_dataframe() on 2D seismic chunks are now working even if the seismic line has more than 407 samples.

  • #43129 Type error instead of PythonToolException when trying to set SEG-Y cube chunk with Pandas DataFrame -

When trying to update a chunk of a SEG-Y seismic cube using a Pandas DataFrame the error message now correctly states that the chunk is readonly.

  • #43161 Setting chunk with DataFrame IJK values not matching chunk IJK values raises incorrect IndexError -

If the IJK values of the DataFrame provided to set() method does not match the IJK values of the chunk, the ValueError is now correctly raised.

  • #43150 Incorrect exception raised when changing readonly status of seismic calculator cube -

Seismic data created in the Petrel calculator is readonly and the exception message when trying to modify readonly status is corrected.

  • #43356 NameError after open() method -

Using the open() method on PetrelConnection class 60 minutes after first execution resulted in a name error. Refresh token had to be deleted manually to connect to Petrel again. This is fixed in the newest version.

What’s new in Blueback Python Tool Pro 1.1#

New features#

Blueback Python Tool Pro v1.1 has the following new functionalities:

  • Support for new domain object wavelets

  • Support for new domain object well surveys

  • Support for new domain object seismic horizon


Wavelet support allows the user to retrieve wavelet objects from Petrel. Retrieving the wavelet from Petrel gives you the position and amplitude of the wavelet. You can load these values into a Pandas DataFrame, print the amplitudes as Numpy array, set new values and create a clone of the wavelet object.

Well surveys#

Well survey support allows the user to retrieve well survey objects from Petrel. Python Tool Pro supports all 5 types of Petrel well surveys:

  • MD, Incl, Azim

  • DX, DY, TVD

  • X,Y,Z

  • X,Y,TVD

  • Explicit survey

Retrieving the well surveys allows the user to load the trajectory path into a Pandas DataFrame, get the well survey type, the azimuth reference, and the MD of the tie-in for lateral wells. Python Tool Pro does not differentiate between the different well survey types when working in the Python API. By using the set() method to update the trajectory path the user will only be able to update the columns according to the well survey type in Petrel. The user can use Python Tool Pro to set the retrieved well survey as definitive survey in Petrel by using the set_survey_as_definitive() method.

Seismic horizon#

Seismic horizons can be retrieved from Petrel. 3d interpretation grids can be access from their parent seismic horizon.

Changed features#

Enhancements have been made to the following features in Blueback Python Tool Pro version 1.1:

  • Virtual seismic read-only status

  • As_array() introduced as alias for get_rawvalues()

  • Added TVD support to the well log API

Virtual seismic read-only status#

When trying to change the read-only status of virtual seismic cube an exception is raised that virtual seismic is always read-only.

as_array() introduced as alias for get_rawvalues()#

When working with chunks, you can now use the method as_array() instead of get_rawvalues().

Added TVD support to the well log API#

When using as_dataframe() method on the well log or discrete well log, the TVD of the well is also retrieved.

Deleted features#

No deleted features.

Bug fixes#

  • Set values of seismic cubes - When setting values of a seismic cube with bulk value format of integer 8 bit or integer 16 bit outside of the original seismic cube amplitude range an exception is raised.

  • Exception when cloning empty polygon with copy_values=True - Cloning a polygon without attributes using the flag copy_values=True does not throw an exception anymore.

  • Using property ‘well’, ‘borehole’, and ‘global_well_log’ on discrete well log no longer outputs blank value

  • Using ‘logs’ property on discrete global well log is no longer raising AttributeError

  • Using method log() on global well log or discrete global well log is no longer raising AttributeError

  • Discrete global well log placed inside the folder in the Petrel’s input tree now includes parent folder in the path

  • When defining a chunk from an object, the extent of the object is checked, and an exception is now raised if trying to define a chunk outside of the object’s extent