>HESTIA Data Validation>Site validation

Site validation


Here is the list of validations running on a Site.

Validate coordinates of inland Site

When using coordinates, the Site must be inland.

Validate the siteType

This validation uses this layer from Google Earth Engine, to validate that the correct siteType has been set. This only gives a warning.

Validate multiple Cycles with identical dates related to the same Site

This validation prevents connecting multiple Cycles to the same Site, during the same period. If multiple products are being produced on the same Site, they should be added together in the same Cycle. Otherwise, different Site must be used.

Note: this applies to the Cycles linked with .site and .otherSites.

Validate Cycles linked via Impact Assessment

When linking 2 Cycles together with an Impact Assessment, they can not be linked to the same Site. Example of incorrect link:

  • Cycle1 and Cycle2 are linked to Site1;
  • one Input of Cycle1 has .impactAssessment=Impact1;
  • the .cycle of Impact1 points to Cycle2.
    This is not allowed, as it will create a circular dependency while calculating Site1. Instead, Cycle1 and Cycle2 should be linked to 2 different Sites.

Validate that a certain date must be before the current date

Validate Dates

This validation ensures two things:

  1. The endDate must be later than startDate;
  2. The date format of endDate must be the same as startDate.

Validate the format of endDate and startDate

This validation is to ensure that the startDate and endDate formats match, for any blank node.

Validate dates and value items

This validation ensures that the number of items in value and dates are identical.

Validate blank node value between provided min and max

For any blank node, if the value is not between the min and max fields, an error will be given.

Validate blank node max is below provided min

For any blank node, if the max is not greater than the min field, an error will be given.

Validate blank node value between the lookup minimum and maximum

For some Terms, HESTIA has defined some minimum and maximum value. If the specified value does not fall within these, an error is raised.

Validate property value based on a lookup value

This validation checks if the property value provided is consistent with the value stored in a lookup table. For example, we can use the lookup region-liveAnimal-liveweightPerHead.csv file to determine if the liveweightPerHead value provided is within 75% of the high value contained in the lookup, for the country.

Validate duplicated nodes

This validation gives a warning when 2 identical nodes, with different id value`, are detected.

Validates the percentage of blank nodes

For all Terms that are in percentages, the value must be between 0 and 100.

Validate a group of blank nodes must sum to 100%

Some Terms are part of a group from the lookup sumIs100Group, meaning when summed up, their total value must be exactly 100% (with a 5% tolerance).

Validate the value of some blank nodes when the units is a percentage

For all Terms that are set as percentages, the value must be provided.

Validate the type of the value of blank nodes

Using the lookup "valueType", this validation will make sure the provided value is of the correct type. Example: a Term that should be either True or False will only accept True/False value.

Validate that some properties are specified for each blank nodes

Using the lookup recommendedPropertyTermIds on a blank node term, this validation will suggest the user to add any missing Property. These properties are necessary to run the models, and should be specified to prevent HESTIA from using default properties.

Validate that the region is not a Country

When using the region field, it must point to GADM Terms that are not countries. This can be identified with the gadmLevel field: it must be > 0 to be a region.

Validate that the region is within the country

When using both country and region, the region must be within the country specified.

Validate that the country is a Country

When using the country field, it must point to GADM Terms that are countries. This can be identified with the gadmLevel field: it must be == 0 to be a country.

Validate the coordinates are within the region or country

When providing longitude and latitude, the coordinates must fall within the region or country provided.

Validate area based on boundary

HESTIA will calculate the boundary area during upload, and this validation will show a warning when the area does not match. Please verify that the area provided is correct and in the correct unit.

Validate max boundary size

HESTIA will only gap-fill data from Geospatial datasets when the site area is less than 5000km2. If you see this warning, it means the calculation will be incomplete, and the measurements will need to be manually provided. Please provide a smaller polygon instead.

Validate max region/country size

HESTIA will only gap-fill data from Geospatial datasets when the site area is less than 5000km2. If you see this warning, it means the calculation will be incomplete, and the measurements will need to be manually provided. Please provide a smaller region/country instead.

Validates empty fields

This validation returns warnings when fields are added without a value (or using 'no data' for example).

Validate the privacy of 2 linked Nodes

When adding a Source to a Cycle or an ImpactAssessment, this validation ensures that the same level of privacy is used on both.

Example:

  • if the Cycle is set as dataPrivate=true, the Source it is linked to must also be dataPrivate=true;
  • if the Cycle is set as dataPrivate=false, the Source it is linked to must also be dataPrivate=false.

Validate private nodes are linked to a Source

It is recommended to always link a Cycle, Site, or ImpactAssessment, to a Source, even when private.

Validate a blank node value based on HESTIA's model

This validation will use the models library to recalculate the value of a blank node, and will give an error when the value too different from the models value. Note: the default tolerance is 5%, but we use the lookup valueToleranceToHestiaRecalculatedValue when available.

Validate multiple terms used with different units

Some of the terms in the Glossary have been added with different units, e.g., kg / kg N / kg VS. This validation returns a warning when those terms have been used together in the same Node.

Validate usage of "Other model"

The "Other model" Term has been added in the eventuality that HESTIA has not added the required model yet. However, to use this Term, the methodModelDescription must be set.

Validate when a non-indexed node references indexed nodes

When uploading Cycle, Site, etc., the referenced nodes must also be uploaded. Example:

  • if the uploaded Cycle references an existing Site, a warning will be given;
  • if the uploaded Cycle references an uploaded Site, no warning is given.

Validate defaultLifespan

This validation will give an error if the duration between the start and the end dates is not equal to the defaultLifespan.

Validate infrastructure functionalArea

This validation gives a warning when an Infrastructure specifies a mass, area or inputs.value but neither the site.area nor the Infrastructure functionalArea are provided.

Validate soil texture measurements

Given a certain soilTexture, this validation will make sure the values for sandContent, siltContent, and clayContent are within accepted ranges. To fix this error, please use the correct values for those measurements, or change the soilTexture.

Validate depthUpper and depthLower values

Validate depthLower >= depthUpper.

Validate using depths on measurements

Some measurements need to have the depthUpper and depthLower to be used in the calculations. This validation will give an error for some measurements that have been flagged as requiring depths (see depthSensitive lookup).

Validate adding measurement only once

Some measurements can only be added once per Site. Using the lookup oneMeasurementPerSite, this validation will give an error in the following cases:

  • when a Term is being used more than once.
  • when a Term is used only once, but without a value or a min and max number.

Validate using dates on measurements

Some measurements need to have the startDate and endDate to be used in the calculations. This validation will give an error for some measurements that have been flagged as requiring dates (see needStartDateEndDate lookup).

Validate value using HESTIA models

For some measurements, we will run our HESTIA models against the value, to make sure it is correct. As our models can differ from real-life measurements, only a warning is given.

Validate measurement value can not be an array

Some measurements can not be added as an array of value. This is validated using the lookup arrayTreatment.

Validate ponds and tanks require setting the water type

This validation gives an error when:

  • the siteType is in the water;
  • none of the "water type" measurements have been provided.

To fix this error, please add one of the following measurements: salineWater, freshWater, brackishWater, or waterSalinity.

Validate water salinity value

This validation will verify the water type and salinity value provided. For example:

  • if waterSalinity is set with value=1000;
  • and freshWater is also set
  • an error will be given, as the correct type should be brackishWater.

To fix this error, either change the waterSalinity value, or set the correct water type.

Validate using soilType or usdaSoilType on measurements

This validation ensures the consistent use of dates and depthUpper/depthLower for each type of measurements.

To fix this error, please add dates and/or depthUpper and depthLower to all Measurements of termType = soilType or usdaSoilType.

Validate the Property value type

This validation checks the type of the Property value, according to the lookup "valueType". To fix this error, you need to change the type of the value, according to the expected type.

Validate the termType used with this property

Some properties can only be used on some term types. When the termType is not allowed, an error is given. To fix this error, you either need to use a different property, or you need to change the term of the blank node. Note: this validation uses the lookup termTypesAllowed on the property.

Validate the property value based on HESTIA's default value

For some properties, HESTIA has set a default value. This validation will give a warning when the provided value is more than 25% different that HESTIA's default value.

Validate Volatile solids content Property for Excreta terms

This validation validates these cases:

  • for Excreta terms with units kg mass, Volatile solids content must be between 0% and 100%;
  • for Excreta terms with units kg VS, Volatile solids content must be 100%;
  • for Excreta terms with units kg N, Volatile solids content must be above 0%.

Validate the property value based on minimum and maximum from the Property or lookups

This validation uses the min and max fields of the Property, or the lookups minimum and maximum, to validate the value.

Validate management blank nodes are specified

This validation gives a warning when no Management blank node has been added on certain siteType.

Validate usage of fallow management

This validation ensures that the duration of the Management "fallow" terms matching the specific duration. For example, shortFallow should be less than 1 year in duration. To fix this error, use the correct "fallow" term based on the duration of the Manamgenent node.

Prevent overlap between management dates and cycle dates

HESTIA will gap-fill Management data from the related Cycles of a Site. Adding data on the same dates of those Cycles could lead to double-counting. We will use the first Cycle startDate, or endDate - cycleDuration, or endDate - maximumCycleDuration lookup to determine the earliest start date of the gap-filling, and prevent using Management dates that are later than this date. You can make sure this error is not triggered by:

  • removing any Management node that describes the Cycles;
  • using day precision for the Management nodes and the Cycle startDate / endDate (e.g., 2000-01-01);
  • making sure the startDate or cycleDuration of the first Cycle is set (so we don't use maximumCycleDuration).