Skip to main content

Location-wise

An ensemble is an attribute where every location has multiple equiprobable values. The location-wise task computes per-location statistics from an ensemble and saves each computed value as a geoscience object attribute. You can request any combination of the following operations in a single call:

  • Summary — minimum, maximum, mean, and variance of all values at each location.
  • Quantiles — one or more quantiles (between 0 and 1) of all values at each location.
  • Probability above cutoffP(value>cutoff)P(\text{value} > \text{cutoff}) for one or more cutoff values at each location.
  • Mean above cutoffE[valuevalue>cutoff]E[\text{value} \mid \text{value} > \text{cutoff}] for one or more cutoff values at each location.

At least one operation must be requested. When multiple operations are provided, all corresponding output attributes are computed in a single run.

Parameters

  • source (object)
  • target (object)
  • summary (boolean, optional)
    • If true, compute summary statistics (min, max, mean, variance) at each location. The task saves four attributes named "min", "max", "mean", and "variance".
  • quantiles (array of numbers, optional)
    • One or more quantile values between 0.0 and 1.0 to compute at each location. The task saves one attribute per quantile, named like "Quantile: {q}".
  • probability_above_cutoff (object, optional)
    • cutoffs (array of numbers) — one or more cutoff values. For each cutoff, the task computes P(value>cutoff)P(\text{value} > \text{cutoff}) at each location and saves an attribute named like "Prob>{cutoff}".
  • mean_above_cutoff (object, optional)
    • cutoffs (array of numbers) — one or more cutoff values. For each cutoff, the task computes E[valuevalue>cutoff]E[\text{value} \mid \text{value} > \text{cutoff}] at each location and saves an attribute named like "Mean>{cutoff}".

Examples

For more information, see the location-wise API reference.

Summary only

requests.post(
"https://{hub}.api.seequent.com/compute/orgs/{org_id}/geostatistics/location-wise",
headers={"Authorization": "Bearer {token}"},
json={
"parameters": {
"source": {
"object": "https://{hub}.api.seequent.com/geoscience-object/orgs/{org_id}/workspaces/{workspace_id}/objects/path/my-grid.json",
"attribute": "cell_attributes[?name=='my-ensemble']",
},
"target": {
"object": "https://{hub}.api.seequent.com/geoscience-object/orgs/{org_id}/workspaces/{workspace_id}/objects/path/my-grid.json",
},
"summary": True,
},
},
)

Quantiles only

requests.post(
"https://{hub}.api.seequent.com/compute/orgs/{org_id}/geostatistics/location-wise",
headers={"Authorization": "Bearer {token}"},
json={
"parameters": {
"source": {
"object": "https://{hub}.api.seequent.com/geoscience-object/orgs/{org_id}/workspaces/{workspace_id}/objects/path/my-grid.json",
"attribute": "cell_attributes[?name=='my-ensemble']",
},
"target": {
"object": "https://{hub}.api.seequent.com/geoscience-object/orgs/{org_id}/workspaces/{workspace_id}/objects/path/my-grid.json",
},
"quantiles": [0.25, 0.5, 0.75],
},
},
)

Multiple operations in one call

requests.post(
"https://{hub}.api.seequent.com/compute/orgs/{org_id}/geostatistics/location-wise",
headers={"Authorization": "Bearer {token}"},
json={
"parameters": {
"source": {
"object": "https://{hub}.api.seequent.com/geoscience-object/orgs/{org_id}/workspaces/{workspace_id}/objects/path/my-grid.json",
"attribute": "cell_attributes[?name=='my-ensemble']",
},
"target": {
"object": "https://{hub}.api.seequent.com/geoscience-object/orgs/{org_id}/workspaces/{workspace_id}/objects/path/my-grid.json",
},
"summary": True,
"quantiles": [0.1, 0.5, 0.9],
"probability_above_cutoff": {
"cutoffs": [0.1, 0.43, 1.2],
},
"mean_above_cutoff": {
"cutoffs": [0.12, 0.67],
},
},
},
)

Result

{
"message": "Location-wise operations computed: SummaryCalculator, QuantilesCalculator, ProbabilityAboveCutoffCalculator, MeanAboveCutoffCalculator.",
"target": {
"reference": "https://{hub}.api.seequent.com/geoscience-object/orgs/{org_id}/workspaces/{workspace_id}/objects/path/my-grid.json",
"schema_id": "/objects/regular-3d-grid/[>=1.2,<2]",
"attributes": [
{"reference": "min", "name": "min"},
{"reference": "max", "name": "max"},
{"reference": "mean", "name": "mean"},
{"reference": "variance", "name": "variance"},
{"reference": "Quantile: 0.1", "name": "Quantile: 0.1"},
{"reference": "Quantile: 0.5", "name": "Quantile: 0.5"},
{"reference": "Quantile: 0.9", "name": "Quantile: 0.9"},
{"reference": "Prob>0.1", "name": "Prob>0.1"},
{"reference": "Prob>0.43", "name": "Prob>0.43"},
{"reference": "Prob>1.2", "name": "Prob>1.2"},
{"reference": "Mean>0.12", "name": "Mean>0.12"},
{"reference": "Mean>0.67", "name": "Mean>0.67"}
]
}
}

Tips

  • The source and target can use the same object, but they don't have to.
  • You can combine any subset of operations in a single request. For example, requesting only summary and quantiles in one call avoids running two separate tasks.
  • The probability_above_cutoff and mean_above_cutoff cutoff lists are independent — they can contain different values.
  • This task replaces the previous location-wise-summary and location-wise-quantiles tasks.

Was this page helpful?