resqpy.well.WellboreMarkerFrame¶
- class resqpy.well.WellboreMarkerFrame(parent_model, uuid=None, trajectory_uuid=None, title=None, originator=None, extra_metadata=None)¶
Bases:
BaseResqpy
Class to handle RESQML WellBoreMarkerFrameRepresentation objects.
Note
measured depth data must be in same crs as those for the related trajectory
Public Data Attributes:
resqml_type
boundary_feature_dict
Inherited from
BaseResqpy
resqml_type
Standard part name corresponding to self.uuid.
XML node corresponding to self.uuid.
Citation block title equivalent to self.title.
Commonly Used Methods:
__init__
(parent_model[, uuid, ...])Creates a new wellbore marker frame object and optionally loads it from xml.
Methods:
from_dataframe
(parent_model, ...[, md_col, ...])Load wellbore marker frame data from a pandas data frame.
Returns a pandas dataframe with columns X, Y, Z, MD, Boundary_Feature_Type, Marker_Citation_Title,
create_xml
([ext_uuid, add_as_part, ...])Creates the xml tree for this wellbore marker frame and optionally adds as a part to the model.
write_hdf5
([file_name, mode])Writes the hdf5 array associated with this object (the measured depth data).
Find wellbore marker index by interpretation uuid.
Returns wellbore marker by index.
Inherited from
BaseResqpy
__init__
(parent_model[, uuid, ...])Creates a new wellbore marker frame object and optionally loads it from xml.
Look for an equivalent existing RESQML object and modify the uuid of this object if found.
create_xml
([ext_uuid, add_as_part, ...])Creates the xml tree for this wellbore marker frame and optionally adds as a part to the model.
append_extra_metadata
(meta_dict)Append a given dictionary of metadata to the existing metadata.
__eq__
(other)Implements equals operator; uses is_equivalent() otherwise compares class type and uuid.
__ne__
(other)Implements not equal operator.
__repr__
()String representation.
- __init__(parent_model, uuid=None, trajectory_uuid=None, title=None, originator=None, extra_metadata=None)[source]¶
Creates a new wellbore marker frame object and optionally loads it from xml.
- Parameters
parent_model (model.Model object) – the model which the new wellbore marker frame belongs to
uuid (uuid.UUID, optional) – If given, loads from disk. Else, creates new.
trajectory_uuid (uuid.UUID, optional) – the uuid of the Trajectory object associated with the well; not used if uuid is not None
title (str, optional) – the citation title to use for a new wellbore marker frame; ignored if uuid is not None
originator (str, optional) – the name of the person creating the wellbore marker frame, defaults to login id; ignored if uuid is not None
extra_metadata (dict, optional) – string key, value pairs to add as extra metadata for the wellbore marker frame; ignored if uuid is not None
- Returns
the newly created wellbore marker frame object
- append_extra_metadata(meta_dict)¶
Append a given dictionary of metadata to the existing metadata.
- property citation_title¶
Citation block title equivalent to self.title.
- create_xml(ext_uuid=None, add_as_part=True, add_relationships=True, title='wellbore marker framework', originator=None)[source]¶
Creates the xml tree for this wellbore marker frame and optionally adds as a part to the model.
- dataframe()[source]¶
Returns a pandas dataframe with columns X, Y, Z, MD, Boundary_Feature_Type, Marker_Citation_Title,
Interp_Citation_Title.
- find_marker_from_index(idx)[source]¶
Returns wellbore marker by index.
- Parameters
idx (int) – position of the marker in the wellbore marker list
- Returns
marker (WellboreMarker object)
- find_marker_index_from_interp(interpretation_uuid)[source]¶
Find wellbore marker index by interpretation uuid.
- Parameters
interpretation_uuid (uuid.UUID or string) – the uuid of the interpretation object of interest
- Returns
integer indicating the associated marker’s position in self.marker_list
Note
if no marker is found for the interpretation uuid, None is returned
- classmethod from_dataframe(parent_model, trajectory_uuid, dataframe, md_col='MD', boundary_feature_type_col='Boundary_Feature_Type', marker_citation_title_col='Marker_Citation_Title', interp_citation_title_col='Interp_Citation_Title', create_organizing_objects_where_needed=True, title=None, originator=None, extra_metadata=None)[source]¶
Load wellbore marker frame data from a pandas data frame.
- Parameters
parent_model (model.Model object) – the model which the new blocked well belongs to
dataframe – a pandas dataframe holding the wellbore marker frame data
trajectory_uuid (uuid.UUID, optional) – the uuid of the Trajectory object associated with the well;
md_col (string, default 'MD') – the name of the column holding measured depth values
boundary_feature_type_col (string, default 'Boundary_Feature_Type') – the name of the column holding the type of geologic, fluid or contact feature; e.g. “fault”, “geobody”, “horizon “, “gas/oil/water down to”, “gas/oil/water up to”, “free water contact”, “gas oil contact”, “gas water contact”, “water oil contact”, “seal”
marker_citation_title_col (string, default 'Marker_Citation_Title') – the name of the column holding the marker citation title
interp_citation_title_col (string, default 'Interp_Citation_Title') – the name of the column holding the interpretation
create_organizing_objects_where_needed (bool, default True) – if True, interpretation and feature objects will be created when needed if they do not already exist; if False, an exception will be raised if a required interpretation is missing
title (str, optional) –
title – the citation title to use for a new wellbore marker frame; ignored if uuid is not None
originator (str, optional) – the name of the person creating the wellbore marker frame, defaults to login id; ignored if uuid is not None
extra_metadata (dict, optional) – string key, value pairs to add as extra metadata for the wellbore marker frame; ignored if uuid is not None
- Returns
the newly created wellbore marker frame object
- property part¶
Standard part name corresponding to self.uuid.
- property root¶
XML node corresponding to self.uuid.
- try_reuse()¶
Look for an equivalent existing RESQML object and modify the uuid of this object if found.
- Returns
boolean – True if an equivalent object was found, False if not
Note
by design this method may change this object’s uuid as a side effect
- write_hdf5(file_name=None, mode='a')[source]¶
Writes the hdf5 array associated with this object (the measured depth data).
- Parameters
file_name (string) – the name of the hdf5 file, or None, in which case the model’s default will be used
mode (string, default 'a') – the write mode for the hdf5, either ‘w’ or ‘a’
- title¶
Citation title
- originator¶
Creator of object. By default, user id.
- uuid¶
Unique identifier