From c6d798767aeb0234ac114892b23d98a9c8a612af Mon Sep 17 00:00:00 2001
From: Tor-Einar Skog <tor-einar.skog@nibio.no>
Date: Mon, 13 Mar 2023 13:11:00 +0100
Subject: [PATCH] Add more details on weather data and pest obs

---
 input_data.md | 63 ++++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 62 insertions(+), 1 deletion(-)

diff --git a/input_data.md b/input_data.md
index df1e760..81af664 100644
--- a/input_data.md
+++ b/input_data.md
@@ -30,7 +30,68 @@ Below is a minimum example of VIPS result data.
 This is the 10-character unique id for the specific model
 
 ## configParameters
-Here are the input data, which are free-form, but by convention weather data are to be found in the `observations` property, and they must follow the [VIPS weather data format](./weather_data.md). Here, we also have a `sowingDate` that this specific model requires.
+Here are the input data, which are free-form. The first one is the `sowingDate` that this specific model requires.
+
+### Weather data
+By convention weather data are to be found in the `observations` property, and they must follow the [VIPS weather data format](./weather_data.md). With observations, we actually mean **all weather data that the model uses; past, present and future**. A typical model expects all weather data to be in one continuous list of observations combining measured data and forecasts. 
+
+
+### PestObservation: Observations/registrations of pests and diseases in the field
+The weather observations follow a standard pattern, and so do the field observations:
+
+```json
+{
+	"pestObservations": [{
+		"timeOfObservation": 1461103200000,
+		"observationData": "{\"trapCountCropEdge\":3,\"trapCountCropInside\":0}",
+		"name": "Lorem Ipsum",
+		"geoinfo": {
+			"type": "FeatureCollection",
+			"features": [
+				{
+				"type": "Feature",
+				"properties": {},
+				"geometry": {
+					"coordinates": [
+					10.44766117815368,
+					59.22486514003208
+					],
+					"type": "Point"
+				}
+				}
+			]
+			}
+	}, {
+		"timeOfObservation": 1461448800000,
+		"observationData": "{\"trapCountCropEdge\":1,\"trapCountCropInside\":5}",
+		"name": "Lorem Ipsum",
+		"geoinfo": {
+			"type": "FeatureCollection",
+			"features": [
+				{
+				"type": "Feature",
+				"properties": {},
+				"geometry": {
+					"coordinates": [
+					10.44766117815368,
+					59.22486514003208
+					],
+					"type": "Point"
+				}
+				}
+			]
+			}
+	}],
+}
+```
+
+The properties are:
+* timeOfObservation - timestamp when the obervation was made [REQUIRED]
+* geoinfo: GeoJson describing the location. May or may not be required by the model
+* name: Title of the observation (not important in models)
+* observationData: Json formatted data quantifying the observation. **The properties vary greatly between the pests**. For each pest observation based models, there is a Json schema for this.
+
+Pest observations may be only one or a series, depending on the model. If no observations available, the model should handle NULL.
 
 ## Usage in a VIPS model
 ### Java
-- 
GitLab