{"id":13719857,"url":"https://github.com/toddheitmann/PetroPy","last_synced_at":"2025-05-07T12:30:40.492Z","repository":{"id":57452023,"uuid":"93205604","full_name":"toddheitmann/PetroPy","owner":"toddheitmann","description":"A petrophysics python package for geoscience python computing of conventional and unconventional formation evaluation. Reads las files and creates a pandas dataframe of the log data. Includes a basic petrophysical workflow and a simple log viewer based on XML templates.","archived":false,"fork":false,"pushed_at":"2019-05-21T02:44:18.000Z","size":17965,"stargazers_count":186,"open_issues_count":10,"forks_count":66,"subscribers_count":25,"default_branch":"master","last_synced_at":"2025-04-19T19:06:52.507Z","etag":null,"topics":["formation-evaluation","geoscience","petrophysics","reservoir-characterization"],"latest_commit_sha":null,"homepage":"https://toddheitmann.github.io/PetroPy/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/toddheitmann.png","metadata":{"files":{"readme":"README.rst","changelog":"changelog.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-06-02T21:36:11.000Z","updated_at":"2025-04-17T21:26:08.000Z","dependencies_parsed_at":"2022-09-02T06:43:48.872Z","dependency_job_id":null,"html_url":"https://github.com/toddheitmann/PetroPy","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/toddheitmann%2FPetroPy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/toddheitmann%2FPetroPy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/toddheitmann%2FPetroPy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/toddheitmann%2FPetroPy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/toddheitmann","download_url":"https://codeload.github.com/toddheitmann/PetroPy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252876286,"owners_count":21818156,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["formation-evaluation","geoscience","petrophysics","reservoir-characterization"],"created_at":"2024-08-03T01:00:56.802Z","updated_at":"2025-05-07T12:30:35.457Z","avatar_url":"https://github.com/toddheitmann.png","language":"Python","funding_links":[],"categories":["Software"],"sub_categories":["Well Log"],"readme":".. image:: https://toddheitmann.github.io/PetroPy/_images/petropy_logo.png\n\nPetroPy\n=======\n\nA python petrophysics package allowing scientific python computing\nof conventional and unconventional formation evaluation. Reads las\nfiles using `lasio \u003chttps://github.com/kinverarity1/lasio\u003e`__. Includes\na petrophysical workflow and a log viewer based on XML templates.\n\n.. image:: https://toddheitmann.github.io/PetroPy/_images/university_6-18W_no1.png\n\nRequirements\n------------\n\n-  `cchardet \u003chttps://github.com/PyYoshi/cChardet\u003e`__\n-  `lasio \u003chttps://github.com/kinverarity1/lasio\u003e`__\n-  `numpy \u003chttp://www.numpy.org\u003e`__\n-  `scipy \u003chttps://www.scipy.org\u003e`__\n-  `pandas \u003chttp://pandas.pydata.org\u003e`__\n-  `matplotlib \u003chttp://matplotlib.org\u003e`__\n-  `scikit-learn \u003chttp://scikit-learn.org/stable/\u003e`__\n\nInstallation\n------------\n\nInstall PetroPy through pip via the command line\n\n.. code-block:: bash\n\n  pip install petropy\n\nTo read in an las file, pass the file reference:\n\n.. code-block:: python\n\n  import petropy as ptr\n  file_path = r'path/to/well.las'\n  log = ptr.Log(file_path)\n\nDocumentation\n-------------\n\nView the `online documentation`_ for classes and methods.\n\n.. _online documentation: https://toddheitmann.github.io/PetroPy/\n\nLas File Processing\n-------------------\n\nTo understanding using petropy in a petrophysical workflow for las file\nprocessing, see the `example page`_.\n\n.. _example page: https://toddheitmann.github.io/PetroPy/auto_examples/\n\nPetrophysical Model Quick Look\n------------------------------\n\n.. code-block:: python\n\n  \u003e\u003e\u003e # import petropy and print raw curves\n  \u003e\u003e\u003e import petropy as ptr\n  \u003e\u003e\u003e log = ptr.log_data('WFMP')\n  \u003e\u003e\u003e print(log.curves)\n\n.. code-block:: bash\n\n  Mnemonic   Unit  Value         Description\n  --------   ----  -----         -----------\n  DEPT       F     00 000 00 00  1  Depth Curve\n  CALI       INCH  99 075 22 05  2  CALIPER\n  DPHI       DECP  99 075 22 05  3  DENSITY POROSITY -LIME-\n  GR         GAPI  99 075 22 05  4  GAMMA RAY\n  NPHI       DECP  99 075 22 05  5  NEUTRON POROSITY -LIME-\n  PE         B/E   99 075 22 05  6  PHOTO-ELECTRIC FACTOR\n  RHOB       G/C3  99 075 22 05  7  BULK DENSITY\n  PHIX       DECP  99 075 22 05  8  CROSSPLOT POROSITY\n  C13        INCH  99 075 22 05  9  CALIPER PADS 1 - 3    -FACT-\n  C24        INCH  99 075 22 05  10  CALIPER PADS 2 - 4    -FACT-\n  DT         US/F  99 075 22 05  11  SONIC TRANSIT TIME\n  SPHI       DECP  99 075 22 05  12  SONIC POROSITY  -LIME-\n  GR3              99 075 22 05  13  GAMMA RAY\n  ILD        OHMM  99 075 22 05  14  IL, DEEP RESISTIVITY\n  ILM        OHMM  99 075 22 05  15  IL, MEDIUM RESISTIVITY\n  SGRD       OHMM  99 075 22 05  16  SHORT GUARD RESISTIVITY\n  SP         MV    99 075 22 05  17  SPONTANEOUS POTENTIAL\n  CAL_N      INCH  99 075 22 05  9  CALIPER PADS 1 - 3    -FACT-\n  GR_N       GAPI  99 075 22 05  4  GAMMA RAY\n  RESMED_N   OHMM  99 075 22 05  15  IL, MEDIUM RESISTIVITY\n  RESDEEP_N  OHMM  99 075 22 05  14  IL, DEEP RESISTIVITY\n  NPHI_N     DECP  99 075 22 05  5  NEUTRON POROSITY -LIME-\n  DPHI_N     DECP  99 075 22 05  3  DENSITY POROSITY -LIME-\n  SPHI_N     DECP  99 075 22 05  12  SONIC POROSITY  -LIME-\n  PE_N       B/E   99 075 22 05  6  PHOTO-ELECTRIC FACTOR\n  RHOB_N     G/C3  99 075 22 05  7  BULK DENSITY\n  DTC_N      US/F  99 075 22 05  11  SONIC TRANSIT TIME\n  SP_N       MV    99 075 22 05  17  SPONTANEOUS POTENTIAL\n\n.. code-block:: python\n\n  \u003e\u003e\u003e # read tops into Log object and print\n  \u003e\u003e\u003e log.tops_from_csv()\n  \u003e\u003e\u003e print(log.tops)\n\n.. code-block:: bash\n\n  {'WFMPA': 6993.5, 'WFMPB': 7294.0, 'WFMPC': 7690.5, 'WFMPD': 8028.0}\n\n.. code-block:: python\n\n  \u003e\u003e\u003e # load default parameters and print values\n  \u003e\u003e\u003e log.fluid_properties_parameters_from_csv()\n  \u003e\u003e\u003e print(log.fluid_properties_parameters.keys())\n\n.. code-block:: bash\n\n  dict_keys(['default', 'WFMP'])\n\n.. code-block:: python\n\n  \u003e\u003e\u003e # specificy formation intervals\n  \u003e\u003e\u003e f = ['WFMPA', 'WFMPB', 'WFMPC']\n  \u003e\u003e\u003e # calculate fluid properties for defined formations\n  \u003e\u003e\u003e log.formation_fluid_properties(f, parameter = 'WFMP')\n  \u003e\u003e\u003e # print curves for description of calculated curves\n  \u003e\u003e\u003e print(log.curves)\n\n.. code-block:: bash\n\n  Mnemonic    Unit  Value         Description\n  --------    ----  -----         -----------\n  DEPT        F     00 000 00 00  1  Depth Curve\n  CALI        INCH  99 075 22 05  2  CALIPER\n  DPHI        DECP  99 075 22 05  3  DENSITY POROSITY -LIME-\n  GR          GAPI  99 075 22 05  4  GAMMA RAY\n  NPHI        DECP  99 075 22 05  5  NEUTRON POROSITY -LIME-\n  PE          B/E   99 075 22 05  6  PHOTO-ELECTRIC FACTOR\n  RHOB        G/C3  99 075 22 05  7  BULK DENSITY\n  PHIX        DECP  99 075 22 05  8  CROSSPLOT POROSITY\n  C13         INCH  99 075 22 05  9  CALIPER PADS 1 - 3    -FACT-\n  C24         INCH  99 075 22 05  10  CALIPER PADS 2 - 4    -FACT-\n  DT          US/F  99 075 22 05  11  SONIC TRANSIT TIME\n  SPHI        DECP  99 075 22 05  12  SONIC POROSITY  -LIME-\n  GR3               99 075 22 05  13  GAMMA RAY\n  ILD         OHMM  99 075 22 05  14  IL, DEEP RESISTIVITY\n  ILM         OHMM  99 075 22 05  15  IL, MEDIUM RESISTIVITY\n  SGRD        OHMM  99 075 22 05  16  SHORT GUARD RESISTIVITY\n  SP          MV    99 075 22 05  17  SPONTANEOUS POTENTIAL\n  CAL_N       INCH  99 075 22 05  9  CALIPER PADS 1 - 3    -FACT-\n  GR_N        GAPI  99 075 22 05  4  GAMMA RAY\n  RESMED_N    OHMM  99 075 22 05  15  IL, MEDIUM RESISTIVITY\n  RESDEEP_N   OHMM  99 075 22 05  14  IL, DEEP RESISTIVITY\n  NPHI_N      DECP  99 075 22 05  5  NEUTRON POROSITY -LIME-\n  DPHI_N      DECP  99 075 22 05  3  DENSITY POROSITY -LIME-\n  SPHI_N      DECP  99 075 22 05  12  SONIC POROSITY  -LIME-\n  PE_N        B/E   99 075 22 05  6  PHOTO-ELECTRIC FACTOR\n  RHOB_N      G/C3  99 075 22 05  7  BULK DENSITY\n  DTC_N       US/F  99 075 22 05  11  SONIC TRANSIT TIME\n  SP_N        MV    99 075 22 05  17  SPONTANEOUS POTENTIAL\n  PORE_PRESS  psi                 Calculated Pore Pressure\n  RES_TEMP    F                   Calculated Reservoir Temperature\n  NES         psi                 Calculated Net Effective Stress\n  RW          ohmm                Calculated Resistivity Water\n  RMF         ohmm                Calculated Resistivity Mud Filtrate\n  RHO_HC      g/cc                Calculated Density of Hydrocarbon\n  RHO_W       g/cc                Calculated Density of Water\n  RHO_MF      g/cc                Calculated Density of Mud Filtrate\n  NPHI_HC     v/v                 Calculated Neutron Log Response of Hydrocarbon\n  NPHI_W      v/v                 Calculated Neutron Log Response of Water\n  NPHI_MF     v/v                 Calculated Neutron Log Response of Mud Filtrate\n  MU_HC       cP                  Calculated Viscosity of Hydrocarbon\n  BO                              Calculated Oil Formation Volume Factor\n  BP          psi                 Calcualted Bubble Point\n\n.. code-block:: python\n\n  \u003e\u003e\u003e # load default multimineral parameters\n  \u003e\u003e\u003e log.multimineral_parameters_from_csv()\n  \u003e\u003e\u003e # print available default formation parameters\n  \u003e\u003e\u003e print(log.multimineral_parameters.keys())\n\n.. code-block:: bash\n\n  dict_keys(['default', 'WFMP'])\n\n.. code-block:: python\n\n  \u003e\u003e\u003e # calculate mulitmineral model over defined formations\n  \u003e\u003e\u003e # with parameter 'WFMP'\n  \u003e\u003e\u003e log.formation_multimineral_model(f, parameter = 'WFMP')\n  \u003e\u003e\u003e log.write('processed_log.las')\n  \u003e\u003e\u003e # print curves for description of calculated curves\n  \u003e\u003e\u003e print(log.curves)\n\n.. code-block:: bash\n\n  Mnemonic    Unit   Value         Description\n  --------    ----   -----         -----------\n  DEPT        F      00 000 00 00  1  Depth Curve\n  CALI        INCH   99 075 22 05  2  CALIPER\n  DPHI        DECP   99 075 22 05  3  DENSITY POROSITY -LIME-\n  GR          GAPI   99 075 22 05  4  GAMMA RAY\n  NPHI        DECP   99 075 22 05  5  NEUTRON POROSITY -LIME-\n  PE          B/E    99 075 22 05  6  PHOTO-ELECTRIC FACTOR\n  RHOB        G/C3   99 075 22 05  7  BULK DENSITY\n  PHIX        DECP   99 075 22 05  8  CROSSPLOT POROSITY\n  C13         INCH   99 075 22 05  9  CALIPER PADS 1 - 3    -FACT-\n  C24         INCH   99 075 22 05  10  CALIPER PADS 2 - 4    -FACT-\n  DT          US/F   99 075 22 05  11  SONIC TRANSIT TIME\n  SPHI        DECP   99 075 22 05  12  SONIC POROSITY  -LIME-\n  GR3                99 075 22 05  13  GAMMA RAY\n  ILD         OHMM   99 075 22 05  14  IL, DEEP RESISTIVITY\n  ILM         OHMM   99 075 22 05  15  IL, MEDIUM RESISTIVITY\n  SGRD        OHMM   99 075 22 05  16  SHORT GUARD RESISTIVITY\n  SP          MV     99 075 22 05  17  SPONTANEOUS POTENTIAL\n  CAL_N       INCH   99 075 22 05  9  CALIPER PADS 1 - 3    -FACT-\n  GR_N        GAPI   99 075 22 05  4  GAMMA RAY\n  RESMED_N    OHMM   99 075 22 05  15  IL, MEDIUM RESISTIVITY\n  RESDEEP_N   OHMM   99 075 22 05  14  IL, DEEP RESISTIVITY\n  NPHI_N      DECP   99 075 22 05  5  NEUTRON POROSITY -LIME-\n  DPHI_N      DECP   99 075 22 05  3  DENSITY POROSITY -LIME-\n  SPHI_N      DECP   99 075 22 05  12  SONIC POROSITY  -LIME-\n  PE_N        B/E    99 075 22 05  6  PHOTO-ELECTRIC FACTOR\n  RHOB_N      G/C3   99 075 22 05  7  BULK DENSITY\n  DTC_N       US/F   99 075 22 05  11  SONIC TRANSIT TIME\n  SP_N        MV     99 075 22 05  17  SPONTANEOUS POTENTIAL\n  PORE_PRESS  psi                  Calculated Pore Pressure\n  RES_TEMP    F                    Calculated Reservoir Temperature\n  NES         psi                  Calculated Net Effective Stress\n  RW          ohmm                 Calculated Resistivity Water\n  RMF         ohmm                 Calculated Resistivity Mud Filtrate\n  RHO_HC      g/cc                 Calculated Density of Hydrocarbon\n  RHO_W       g/cc                 Calculated Density of Water\n  RHO_MF      g/cc                 Calculated Density of Mud Filtrate\n  NPHI_HC     v/v                  Calculated Neutron Log Response of Hydrocarbon\n  NPHI_W      v/v                  Calculated Neutron Log Response of Water\n  NPHI_MF     v/v                  Calculated Neutron Log Response of Mud Filtrate\n  MU_HC       cP                   Calculated Viscosity of Hydrocarbon\n  BO                               Calculated Oil Formation Volume Factor\n  BP          psi                  Calcualted Bubble Point\n  PHIE        v/v                  Effective Porosity\n  SW          v/v                  Water Saturation\n  SHC         v/v                  Hydrocarbon Saturation\n  BVH         v/v                  Bulk Volume Hydrocarbon\n  BVW         v/v                  Bulk Volume Water\n  BVWI        v/v                  Bulk Volume Water Irreducible\n  BVWF        v/v                  Bulk Volume Water Free\n  BVOM        v/v                  Bulk Volume Fraction Organic Matter\n  BVCLAY      v/v                  Bulk Volume Fraction Clay\n  BVPYR       v/v                  Bulk Volume Fraction Pyrite\n  VOM         v/v                  Matrix Volume Fraction Organic Matter\n  VCLAY       v/v                  Matrix Volume Fraction Clay\n  VPYR        v/v                  Matrix Volume Fraction Pyrite\n  RHOM        g/cc                 Matrix Density\n  TOC         wt/wt                Matrix Weight Fraction Organic Matter\n  WTCLAY      wt/wt                Matrix Weight Fraction Clay\n  WTPYR       wt/wt                Matrix Weight Fraction Pyrite\n  BVQTZ       v/v                  Bulk Volume Fraction Quartz\n  VQTZ        v/v                  Matrix Volume Fraction Quartz\n  WTQTZ       wt/wt                Matrix Weight Fraction Quartz\n  BVCLC       v/v                  Bulk Volume Fraction Calcite\n  VCLC        v/v                  Matrix Volume Fraction Calcite\n  WTCLC       wt/wt                Matrix Weight Fraction Calcite\n  BVDOL       v/v                  Bulk Volume Fraction Dolomite\n  VDOL        v/v                  Matrix Volume Fraction Dolomite\n  WTDOL       wt/wt                Matrix Weight Fraction Dolomite\n  OIP         wt/wt                Matrix Weight Fraction Dolomite\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftoddheitmann%2FPetroPy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftoddheitmann%2FPetroPy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftoddheitmann%2FPetroPy/lists"}