Book a demo
  1. Home
  2. Articles
  3. Data & platform

Predictive analytics · worked example · North Oman

Predictive drilling analytics: physics, rules and machine learning

DrillIQ drilling engineeringUpdated 1 October 202612 min read

Predictive analytics on a rig has one job: show a developing problem early enough to act, and stay quiet the rest of the time. This article sets out the three tools it is built from, physics models, rules and machine learning, and then runs three pack-off detectors on the same 21 hours of a horizontal well, counting the warning each gives and the false alarms it costs.

What predictive means on a rig

Most drilling problems announce themselves. A pack-off raises the standpipe pressure and the torque before the string sticks; a kick shows in the pits before it shows at the BOP; a failing pump needs more strokes for the same flow. "Predictive" mostly means catching those trends while they are still small.

Three numbers judge any detector. Lead time is how long before the worst moment the alarm comes. Missed events are problems it never flags. False alarms are alarms with no problem behind them. The last one is easy to undervalue. A driller who sees ten false alarms a shift stops reading the eleventh, and from then on the system detects nothing at all. Alarm-management practice in the process industries makes the same point: every alarm must need an operator action.

Physics, rules and machine learning

Physics models give the value a channel should read now: the hook load from a torque and drag model, the standpipe pressure for this flow and depth, the pit volume after the displacement of the pipe run. The difference between measured and expected, the residual, removes everything the model explains, such as depth, flow rate and pipe movement. What is left is the part worth watching.

Rules turn a residual into a decision. A limit, a time it must persist, a lower limit to clear again, the rig states in which it is not read, and a second sign that must agree before a Warning. Rules are transparent: the crew can see the value, the limit and why it fired.

Machine learning learns a pattern from labelled examples. It is strongest where labels are plentiful and physics is weak, such as classifying rig states from surface sensors, where thousands of hours are labelled. It is weakest where events are rare and every well is different, such as stuck pipe, where a few dozen labelled events must cover every rock, string and crew.

DrillIQ uses each where it fits. Its stuck-pipe engine is physics plus rules: it compares the hook load, torque and pressure with a calibrated string model and the well's own connection references. Its rig-state detector is rule-based in production, with gradient-boosted classifiers running in shadow, scored against corrected labels, and promoted only when they agree with those labels at least 90 % of the time on average and 85 % on the worst well. An earlier unsupervised anomaly model was removed from the stuck-pipe engine because it gave normal drilling a severity well above zero, so every reading carried a floor of noise into the risk score.

The residual method for standpipe pressure

A pack-off shows first as pressure: cuttings or cavings narrow the annulus and the pump has to push harder. The expected pressure comes from the run's own connections. At each connection the engine records the pressure on bottom and off bottom with the flow rate, and while drilling it takes the three references nearest in depth among the last ten at a similar rate:

Pexp = median[ Pref (Q / Qref)1.8 ]   over references with |Q / Qref − 1| ≤ 0.10

r = Pmeas − Pexp

Watch: r ≥ max(100 psi, 0.05 Pexp)   Warning: r ≥ max(200 psi, 0.08 Pexp) and a second sign

Pmeas
the measured pressure, a one-minute median while the pumps hold a steady rate
Q, Qref
the flow now and at the reference; the exponent 1.8 is turbulent flow's
second sign
torque, returns or pick-up drag past its own Watch limit; pressure alone stays at Watch while rotating

The engine refuses to stretch a reference more than 10 % in flow, or to extrapolate in depth. A baseline built that way can be wrong by a large margin, and a wrong baseline means false alarms. An alarm then needs 45 seconds of persistence to open and five minutes back at normal to clear.

The example lateral

The example is the 6⅛″ lateral of our stuck-pipe article, set in conditions typical of North Oman: a carbonate reservoir at 1,500 m TVD, 1.12 SG drill-in fluid and 4″ drill pipe. We take 21 hours of 5-second surface data, drilling from the 7″ shoe at 1,760 m to 2,108 m, with connections, a wiper trip and a 75-minute static period. The driller runs 280 gpm while rotating, for hole cleaning, and drops to 240 gpm on the two slid stands for tool-face control. Into this we inject the stuck-pipe engine's own test pack-offs: three 20-minute ramps of 350 psi and 2.5 kft·lbf, one of them while sliding.

The 21 hours and the three pack-offs
Drilling11 klbf WOB, 70 rpm, 280 gpm rotating and 240 gpm sliding, 12 stands from 1,760 m to 2,108 m
Pressure3,181 psi at 280 gpm and 2,410 psi at 240 gpm at the shoe, rising 0.38 psi per metre drilled
Pack-off 1Sliding at 240 gpm, 1,890 m, building 11:50–12:10
Pack-off 2Rotating at 280 gpm, 1,978 m, building 15:54–16:14
Pack-off 3Rotating at 280 gpm, 2,060 m, building 20:02–20:22

A hand check of the pressures

  1. Flow. At 266 gpm the standpipe reads 2,900 psi while drilling. At 280 gpm that becomes 2,900 × (280 / 266)1.8 = 3,181 psi; at 240 gpm, 2,900 × (240 / 266)1.8 = 2,410 psi. The rate change alone moves the pressure 771 psi, more than twice a pack-off.
  2. Drill pipe bore. At 280 gpm the mud moves at 10.25 ft/s in the 3.340″ bore. With the turbulent relation for a Bingham fluid, ρ0.75v1.75μp0.25 / (1,800 d1.25), the loss is 0.0748 psi/ft, or 0.245 psi per metre of pipe.
  3. Annulus. Around the 4″ pipe in 6⅛″ hole the mud moves at 5.32 ft/s; the laminar Bingham loss, μpv / 1,000(d2 − d1)² + τy / 200(d2 − d1), is 0.040 psi/ft, 0.131 psi per metre.
  4. Depth. Each metre drilled adds both: 0.38 psi. Over this window that is 132 psi; over the whole 1,000 m lateral, 380 psi.
  5. Limits. At an expected 3,222 psi the Watch line is max(100, 0.05 × 3,222) = 161 psi over it, and Warning 258 psi.

Detector one: a fixed limit

The simplest rule is a limit on the raw channel: alarm when the pressure passes L psi. We swept it from 3,000 to 3,800 psi with DrillIQ's Alerts rule engine, evaluated every 15 seconds with its 30-minute cooldown.

Figure 1 A fixed limit on standpipe pressure: warning gained against setting
  • Rotating pack-off at 1,978 m
  • Rotating pack-off at 2,060 m
  • Settings that alarm on normal drilling in this window
10–24 false alarmssilent here, alarms deeper051015203,2003,3003,4003,5003,6003,7003,800Fixed limit on standpipe pressure (psi)Warning before the worst moment (min)physics residual: 10.7–11.0 minsilent to TD: 3,599 psimisses both above 3,650

The Alerts module's rule (SPPA above the limit, 30-minute cooldown) swept over the same 21 hours. No setting catches the pack-off while sliding at 240 gpm. Silent to TD: normal drilling pressure at 2,759 m, 3,181 + 0.38 psi/m × 999 m + 38 psi of scatter.

Set at 3,300 psi or below, the limit fires on normal rotating pressure: 10 false alarms in the 21 hours at 3,300, 30 at 3,000. Between 3,350 and 3,600 it is silent and catches both rotating pack-offs. At 3,350 it gives 17 minutes of warning, more than the residual method. That setting was chosen in hindsight, though, and it only works here because the window ends at 2,108 m. Normal drilling pressure reaches 3,350 psi at about 2,105 m, and by TD it is 3,181 + 0.38 × 999 = 3,560 psi, plus 38 psi of scatter. A limit that stays quiet to TD has to sit at about 3,600 psi, where the warning shrinks to 1.5 and 3.2 minutes. And no setting that is silent on normal drilling sees the pack-off while sliding: at 240 gpm the pressure peaks near 2,800 psi, below every useful limit.

Detector two: an automatic band

A statistical band sets the limit from the channel's own history. DrillIQ's Log Viewer channel alarm does this by default: the high limit is the 99th percentile of the channel's last 5,000 samples, recomputed as data arrives, and the alert clears after five minutes back inside. On this window it raised 15 alarms. One fell inside a pack-off, 7.4 minutes before the worst moment of the third; 14 were false. The reason is the depth trend. Pressure keeps rising as the lateral gets longer, so the newest readings keep beating the percentile of the older ones. A band assumes the channel is stationary, and drilling channels rarely are.

Detector three: the physics residual

Figure 2 Standpipe pressure against its expected value, second pack-off
  • Measured (one-minute median)
  • Expected at this flow and depth (engine)
  • Watch and Warning limits
  • A fixed limit, set in hindsight
  • Pack-off building, 15:54–16:14
3,1003,2003,3003,4003,5003,6003,7009.69.810.010.210.4Hours after 06:00 (10.0 = 16:00)Standpipe pressure (psi)fixed limit 3,350 psifixed limit 15:57engine Warning 16:03Warning: +8 %Watch: +5 %Expected16:14 worst+377 psi overexpected

DrillIQ's Stuck Pipe engine on the example lateral, rotating at 280 gpm; the pack-off adds 350 psi and 2.5 kft·lbf over 20 minutes. Expected: the run's connections nearest in depth at the same flow. Limits: the larger of 100 / 200 psi and 5 / 8 % of it.

Show the data
HourMeasuredExpectedWatch limitWarning limit
9.63,2553,2223,3833,480
9.63,2683,2223,3833,480
9.63,2573,2223,3833,480
9.73,2543,2223,3833,480
9.73,2663,2223,3833,480
9.73,2543,2223,3833,480
9.73,2603,2223,3833,480
9.73,2603,2223,3833,480
9.73,2683,2223,3833,480
9.83,2543,2223,3833,480
9.83,2583,2223,3833,480
9.83,2763,2223,3833,480
9.83,2473,2223,3833,480
9.83,2623,2223,3833,480
9.83,2783,2223,3833,480
9.93,2573,2223,3833,480
9.93,2513,2223,3833,480
9.93,2563,2223,3833,480
9.93,2783,2223,3833,480
9.93,2713,2223,3833,480
9.93,2833,2223,3833,480
10.03,3203,2223,3833,480
10.03,3513,2223,3833,480
10.03,3343,2223,3833,480
10.03,3723,2223,3833,480
10.03,3943,2223,3833,480
10.03,3893,2223,3833,480
10.13,4243,2223,3833,480
10.13,4383,2223,3833,480
10.13,4673,2223,3833,480
10.13,4743,2223,3833,480
10.13,4923,2223,3833,480
10.13,5183,2223,3833,480
10.23,5183,2223,3833,480
10.23,5563,2223,3833,480
10.23,5723,2223,3833,480
10.23,5703,2223,3833,480
10.23,5993,2223,3833,480
10.23,2693,2223,3833,480
10.33,2623,2223,3833,480
10.33,2533,2223,3833,480
10.33,2703,2223,3833,480
10.33,2703,2223,3833,480
10.33,2543,2223,3833,480
10.33,2553,2223,3833,480
10.43,2753,2223,3833,480
10.43,2743,2223,3833,480
10.43,2443,2223,3833,480
10.43,2803,2223,3833,480
10.43,2623,2223,3833,480
10.43,2603,2223,3833,480
10.53,2613,2223,3833,480
10.53,2673,2223,3833,480

The second pack-off starts at 15:54. In normal drilling the measured pressure runs 25–55 psi over the expected line, because the references come from connections one or more stands shallower; the Watch line at 161 psi leaves room for that. The residual passes Watch at 16:02. The torque, rising with it, passes its own Watch line within the minute, so the engine goes to Warning at 16:03, 11.0 minutes before the worst moment at 16:14. The third pack-off, deeper, gives 10.7 minutes, with the torque first. Depth and flow rate barely move those numbers, because both are in the expected value.

Three detectors on the same 21 hours
DetectorPack-offs caughtWarning before the worstFalse alarms
Fixed limit 3,300 psi2 of 318.5 and 16.9 min10
Fixed limit 3,350 psi2 of 316.8 and 17.2 min0 here; fires from 2,105 m
Fixed limit 3,600 psi2 of 31.5 and 3.2 min0 to TD
Automatic band, P991 of 37.4 min14
Physics residual, slides at 240 gpm2 of 311.0 and 10.7 min0
Physics residual, slides at 255 gpm3 of 39.5, 11.0 and 10.7 min0

The engine raised one other alarm in the window, and it was real: during the 75-minute static period the string stood still for 21 minutes against the permeable carbonate, past the 20 minutes allowed at 15 bar of overbalance, and the alarm stayed up while the rig circulated without moving the pipe. That is the differential-sticking check doing its job, and it is the kind of alarm the crew should see.

Why the residual missed the slide

The first pack-off came on the first stand slid at 240 gpm. There was no connection reference within 10 % of that rate, so the engine had no expected pressure and the pressure check stayed silent. With the string not rotating, the torque checks were off too. The engine was blind for that stand, and its Mechanisms page showed the pressure check as not known.

We ran the same 21 hours with the slides at 255 gpm, 9 % under the rotating rate. The references then scale to the new rate, and the engine caught the sliding pack-off with 9.5 minutes of warning, and the other two as before. A physics model is only as good as its references. Keep rate changes within 10 % where the hole allows it. Where a bigger change is needed, expect the pressure check to be blind until two connections have been made at the new rate, and watch the pressure by hand meanwhile.

From sensor to decision

A detector is one step in a chain, and the chain fails at its weakest link. The data must be right first: units checked against what the numbers say, null values such as −999.25 removed, a frozen feed flagged rather than read as a steady one. Then context: the rig state decides which checks apply, so pressure is not judged during a connection. Then the model and the rules. Then the alarm itself, carrying its evidence, the measured value against its limit, so the driller can judge it in seconds. Finally the outcome: every alarm acknowledged with a note and labelled real or false. Those labels are how a team learns its true false-alarm rate, and the fairest way to tune a limit.

A checklist for the rig team

  • Count false alarms per shift as carefully as missed events; alarm fatigue switches detection off.
  • Compare a channel with its expected value at the same flow, depth and rig state.
  • Be wary of fixed limits on channels that trend with depth or flow; check where normal operation will cross them.
  • Require a second sign before a Warning wherever one gauge can drift on its own.
  • Keep pump-rate changes within 10 % where possible; after a bigger change, watch pressure by hand until the model has references at the new rate.
  • Run any new model or limit in shadow on replayed wells before it raises live alarms.
  • Acknowledge every alarm with a note and label it real or false.

How DrillIQ handles it

DrillIQ's Alerts & Alarms module evaluates rules on any live channel every 15 seconds, with cooldown, an hourly cap, automatic resolution once the condition has cleared, snooze and escalation, and delivers to the platform, email, an SMS gateway or a webhook. Log Viewer's channel alarms, with manual limits or automatic ones from the channel's percentiles, feed the same list, and the header bell shows every active alarm across wells.

The engineering modules add the physics. Stuck-Pipe Risk raises alarms from residuals against a calibrated string model and the well's connection references, with each alarm's evidence and an outcome label, and its Replay scores the engine against labelled events: lead time, missed events and false alarms, as above. The rig-state classification underneath comes from KPI & Rig State.

Book a demo See all capabilities

References

  1. Bourgoyne, A.T., Millheim, K.K., Chenevert, M.E. and Young, F.S. Applied Drilling Engineering. SPE Textbook Series, Vol. 2, 1986.
  2. Johancsik, C.A., Friesen, D.B. and Dawson, R. Torque and Drag in Directional Wells: Prediction and Measurement. SPE 11380, 1984.
  3. Hempkins, W.B., Kingsborough, R.H., Lohec, W.E. and Nini, C.J. Multivariate Statistical Analysis of Stuck Drillpipe Situations. SPE Drilling Engineering, 1987.
  4. IEC 62682. Management of alarm systems for the process industries. International Electrotechnical Commission.

About this example. The well in this article is a representative scenario set in typical North Oman conditions and worked through with DrillIQ's engines. It is not a client's well, and its figures are not field results.