Skip to main content

Mining — equipment uptime & throughput

The problem. A mine's economics live and die on its haul fleet and processing plant. A haul truck stopped on the ramp is tonnes-per-hour evaporating; a crusher that fails unexpectedly idles everything behind it. The site needs to catch equipment trending toward failure before it stops the line, and to see true throughput against plan so it can act on the bottleneck rather than the loudest radio call.

What we solve here is unplanned downtime and hidden bottlenecks across a fleet of expensive, hard-worked machines.

Set up demo data

New workspace? Run this once (Python) to create a haul truck's oil-pressure series (sagging below its limit) and a crusher throughput series. Safe to re-run.

import datahub_sdk, numpy as np, pandas as pd

client = datahub_sdk.DataHubClient.from_env()

client.timeseries.create([datahub_sdk.TimeSeries(external_id="truck_785_oil_pressure_kpa", name="Truck 785 oil pressure", unit="kpa", value_type="float")])
idx = pd.date_range(end=pd.Timestamp.now(tz="UTC"), periods=60, freq="1min")
op = np.full(60, 320.0); op[-15:] -= np.linspace(0, 90, 15) # sags below 250 kPa
client.timeseries.insert_from_lists(timestamps=idx, values=op, ts="truck_785_oil_pressure_kpa")

client.timeseries.create([datahub_sdk.TimeSeries(external_id="crusher_01_throughput_tph", name="Crusher 01 throughput", unit="tph", value_type="float")])
idx2 = pd.date_range(end=pd.Timestamp.now(tz="UTC"), periods=12, freq="1h")
client.timeseries.insert_from_lists(timestamps=idx2, values=np.random.uniform(1800, 2200, 12), ts="crusher_01_throughput_tph")

Haul-truck engine temperature, oil pressure and payload stream in. A drifting reading raises an equipment_warning before the breakdown, so maintenance is scheduled, not scrambled. See Turn readings into events.

var series = client.timeseries().retrieve(lastHourOf("truck_785_oil_pressure_kpa"))
.getItems().get(0);

if (series.getDatapoints().stream().anyMatch(p -> Double.parseDouble(p.getValue()) < 250.0)) {
EventModel warning = new EventModel();
warning.setExternalId("equipment_warning_785_" + System.currentTimeMillis());
warning.setType("equipment_warning");
warning.setStatus("open");
warning.setMetadata(Map.of("unit", "truck_785", "signal", "oil_pressure"));
warning.setEventTime(ZonedDateTime.now());
client.events().create(List.of(warning));
}

2. See throughput against plan

Payload-per-cycle and cycle counts are series per truck; roll them up to tonnes-per- hour by hour and shift to find where the real bottleneck is — the loader, the haul, or the crusher. See Query & aggregate.

var filter = new RetrieveFilter();
filter.setExternalId("crusher_01_throughput_tph");
filter.setStart(ZonedDateTime.now().minusHours(12));
filter.setEnd(ZonedDateTime.now());
filter.setAggregates(List.of("avg"));
filter.setGranularity("1h");

var request = new DataRetriever<RetrieveFilter>();
request.setItems(List.of(filter));

client.timeseries().retrieve(request).getItems().get(0).getDatapoints()
.forEach(p -> compareToPlan(p.getTimestamp(), p.getValue()));

3. Tie equipment to its place in the flow

Model pit → loader → truck → crusher as a graph so a crusher fault's blast radius — every truck that feeds it — is one traversal away when you plan the workaround.

See the result

The sagging oil pressure trips the predictive rule before the breakdown:

equipment_warning_785_… → open (oil pressure fell below 250 kPa)

See also