# Advanced Inventory
This comprehensive guide covers advanced inventory well prediction workflows in PetroAI, including data preparation, configuration options, offset well handling, and launching builds.
# Overview
There are two key inputs to the PetroAI inventory well prediction process:
- A config file specifying parameters and sensitivity analysis options.
- A data source - the INV_well_features table describes the location and landing information for inventory wells.
Predictions are made using trained models specified in the config file, or a model trained in a previous build. Optionally, feature sensitivities can be run to test varying design options.
# Setting Up Inventory Wells
# 1. Populate the Inventory Wells Source Table
Connect to your source database
Use a database client like DBeaver or MySQL Workbench to connect to your source database. Consult this guide (opens new window) for more information on DBeaver.Generate credentials in PetroAI if needed
If you don't already have access, you can create credentials in PetroAI:- Navigate to the Settings page
- Click on Database
- Click New User
- Create a username and password, and ensure you enable Can Write access
Refer to the table schema guide
Consult this guide (opens new window) for detailed schema definitions and column descriptions to ensure your table is correctly formatted.Ensure clean input data
The inventory build processes all wells in the source table. If there are old or irrelevant wells you don't want included, remove them before running the build.
# 2. Generate the Config File
Start from a previous build
Copy a config file from a successful prior inventory build as your starting point and use the code editor to make any modifications if necessary.Ensure required sections are included
These sections must be present to run inventory predictions and to populate PetroAI Insights dashboards:products
: Defines which pipeline components will be run (core1
,inv
, etc.)phases.shared
: Contains global compute parameters (e.g. frac dimensions, well segments, spacing parameters, etc) that will control well feature attribution.phases.product.raw
: Optimization parameters for downloading time series data.phases.product.core
: Settings related tocore1
phases.product.feature
: Feature experimentation criteria and filtersphases.product.model
: PDP model prediction settingsphases.product.inv
: Configuration specific to inventory predictions, as detailed below.
Important Notes
Inventory wells must contain all features expected by the model. If they are missing, you may need to compute or impute them. Common examples include:- Proppant concentration (
proppant_lb_per_gal
) - Fluid loading (
fluid_gal_per_lb
) wellExtras
fields
- Proppant concentration (
# Configuration Options
For more details on each section and supported syntax, refer to the Build Configuration documentation (opens new window).
# Example Inventory Block
"inv": {
"include_pdps": false,
"max_nearby_pdp_distance_miles": 3,
"valid_pdps_group_name": "empty_group",
"max_midas_parallelization": 30,
"num_years_to_forecast": 40,
"include_timeseries_monthly": true,
"make_plots": true,
"inventory_options": {
"crs_proj4": "+proj=utm +zone=13 +datum=NAD27 +units=m +no_defs"
},
"generate_batch_size": 10,
"partition_options": null,
"well_features_transformations": [
{
"type": "add_uniform_value_column",
"column_name": "operatorName",
"column_dtype": "string",
"column_value": "PetroAI",
"overwrite": true
},
{
"type": "add_uniform_value_column",
"column_name": "totalProppantByPerfLength",
"column_dtype": "float",
"column_value": 2500,
"overwrite": true
},
{
"type": "add_uniform_value_column",
"column_name": "totalFluidByPerfLength",
"column_dtype": "float",
"column_value": 2500,
"overwrite": true
}
],
"sensitivity_features": {
"sampled_features": [
{
"feature": "totalProppantByPerfLength",
"low": 1500,
"high": 3000,
"step": 500
}
],
"linked_features": [
{
"feature": "totalFluidByPerfLength",
"value_expr": "row['totalProppantByPerfLength']"
}
]
}
}
# Creating New Columns with a Fixed Value
Sometimes you must add fixed-value columns to meet model expectations. These transformations go in the well_features_transformations
section.
For example, filtering for a specific operator requires adding the operatorName
column:
"well_features_transformations": [
{
"type": "add_uniform_value_column",
"column_name": "operatorName",
"column_dtype": "string",
"column_value": "PetroAI",
"overwrite": true
}
]
Any columns you wish to run sensitivities on should be included in this section, for example proppant per foot:
"well_features_transformations": [
{
"type": "add_uniform_value_column",
"column_name": "totalProppantByPerfLength",
"column_dtype": "float",
"column_value": 2500,
"overwrite": true
}
]
# Offset PDP Wells
When running inventory predictions, you can choose whether to include offset PDP wells based on your analysis goals. For example, include them to account for existing well effects (e.g. offset child distance), or exclude them to isolate sibling well impacts (e.g. spacing sensitivity analysis).
The system performs a radial search from each inventory well's surface hole location. Any PDP well with a surface hole location within the specified radius—regardless of depth—will be included. Choose a radius large enough to capture relevant offsets without introducing unnecessary wells and compute load.
# Examples
# 1. Include offset PDP wells within a 2 mile radius:
"inv": {
"include_pdps": true,
"max_nearby_pdp_distance_miles": 2,
...
...
}
# 2. Exclude all PDP wells:
"inv": {
"include_pdps": false,
...
...
}
# 3. Custom group of offset PDP wells (Special case):
In some cases, you may want to include or exclude specific PDP wells beyond what a simple radius allows. For these scenarios, contact PetroAI Support for help with custom configuration.
"inv": {
"include_pdps": true,
"valid_pdps_group_name": "PDP_offset_INV_v1.2.7.0",
...
...
}
# Launching the Build
After making any changes in the code editor, click the Save button, then move to the Compute section to launch the build.