Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "CLN: Reorganize main page; remove ophaned pages." #51

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions source/schema/begin_run_event.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"properties": {
"beamline_config": {
"type": ["object", "string"],
"description": "Meta-data regrading how the beamline is configured. Maybe UID into another collection"
},
"project": {
"type": "string",
"description": "Name of project that this run is part of"
},
"sample": {
"type": ["object", "string"],
"description": "Information about the sample, may be a UID to another collection"
},
"beamline_id": {
"type": "string",
"description": "The beamline ID"
},
"scan_id": {
"type": "integer",
"description": "Scan ID number, not globally unique"
},
"time": {
"type": "number",
"description": "Time the run started. Unix epoch time"
},
"uid": {
"type": "string",
"description": "Globally unique ID for tihs run"
},
"group": {
"type": ["string", "integer"],
"description": "Unix group to associate this data with"
},
"owner": {
"type": ["string", "integer"],
"description": "Unix owner to associate this data with"
}
},
"required": [
"uid",
"time",
"group",
"owner",
"beamline_config",
"beamline_id"
],
"type": "object",
"description": "Document created at the start of run. Provides a seach target and later documents link to it"
}
35 changes: 35 additions & 0 deletions source/schema/end_run_event.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@

{
"properties": {
"begin_run_event": {
"type": "string",
"description": "Reference back to the begin run document that this document is paired with."
},
"reason": {
"type": "string",
"description": "Long-form description of why the run ended"
},
"time": {
"type": "number",
"description": "The time the run ended. Unix epoch"
},
"completion_state": {
"type": "string",
"enum": ["success", "abort", "fail"],
"description": "State of the run when it ended"
},
"uid": {
"type": "string",
"description": "Globally unique ID for tihs run"
}
},
"required": [
"uid",
"begin_run_event",
"time",
"completion_state"
],
"type": "object",
"description": "Document for the end of a run indicating the success/fail state of the run and the end time"

}
44 changes: 44 additions & 0 deletions source/schema/ev_desc_doc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
{
"definitions": {
"data_key": {
"properties": {
"external": {
"pattern": "^[A-Z]+:?",
"type": "string"
},
"source": {
"pattern": "^[A-Z]+:",
"type": "string"
}
},
"required": [
"source"
],
"type": "object"
}
},
"properties": {
"begin_run_event": {
"type": "string"
},
"keys": {
"additionalProperties": {
"$ref": "#/definitions/data_key"
},
"type": "object"
},
"time": {
"type": "number"
},
"uid": {
"type": "string"
}
},
"required": [
"uid",
"keys",
"time",
"begin_run_event"
],
"type": "object"
}
47 changes: 47 additions & 0 deletions source/schema/ev_desc_impl.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
{
"definitions": {
"data_key": {
"properties": {
"external": {
"pattern": "^[A-Z]+:?",
"type": "string"
},
"source": {
"pattern": "^[A-Z]+:",
"type": "string"
}
},
"required": [
"source"
],
"type": "object"
}
},
"properties": {
"begin_run_event": {
"type": "string"
},
"data_keys": {
"additionalProperties": {
"$ref": "#/definitions/data_key"
},
"type": "object"
},
"time": {
"type": "number"
},
"id": {
"type": "string"
},
"event_type": {
"type": "string"
}
},
"required": [
"id",
"keys",
"time",
"begin_run_event"
],
"type": "object"
}
75 changes: 75 additions & 0 deletions source/schema/ev_desc_prop.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
{
"definitions": {
"data_key": {
"title": "data_key",
"description": "Describes the objects in the data property of Event documents",
"properties": {
"dtype": {
"enum": [
"string",
"number",
"array",
"boolean",
"integer"
],
"type": "string",
"description": "The type of the data in the event."
},
"external": {
"pattern": "^[A-Z]+:?",
"type": "string",
"description": "Where the data is stored if it is stored external to the events."
},
"shape": {
"items": {
"type": "integer"
},
"type": ["array", "null"],
"destription": "The shape of the data. Null and empty list mean scalar data."
},
"source": {
"pattern": "^[A-Z]+:",
"type": "string",
"description": "The source (ex piece of hardware) of the data."
}
},
"required": [
"source",
"dtype",
"shape"
],
"type": "object"
}
},
"properties": {
"keys": {
"additionalProperties": {
"$ref": "#/definitions/data_key"
},
"type": "object",
"description": "The describes the data to be in the event Documents",
"title": "keys"
},
"uid": {
"type": "string",
"description": "Globally unique ID for this event descriptor.",
"title": "uid"
},
"begin_run_event": {
"type": "string",
"description": "Globally unique ID to the begin_run document this descriptor is associtaed with."
},
"time": {
"type": "number",
"description": "Creation time of the document as unix epoch time."
}
},
"required": [
"uid",
"keys",
"time"
],
"type": "object",
"title": "event_descriptor",
"description": "Document to describe the data captured in the associated event documents"
}
66 changes: 66 additions & 0 deletions source/schema/event.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{
"definitions": {
"data_field": {
"title": "data_field",
"description": "Schema for entries in the event data property",
"items": [
{
"type": [
"string",
"number",
"boolean",
"integer"
],
"description": "The measured value or UID to look up external data",
"title": "value"

},
{
"type": "number",
"description": "The hardware time stamp of this measurement. [s] from unix epoch",
"title": "timestamp"
}

],
"type": "array",
"additionalItems": false,
"minItems": 2
}
},
"properties": {
"data": {
"additionalProperties": {
"$ref": "#/definitions/data_field"
},
"type": "object",
"description": "The actual measument data"
},
"descriptor": {
"type": "string",
"description": "UID to point back to Descriptor for this event stream"
},
"seq_num": {
"type": "integer",
"description": "Sequence number to identify the location of this Event in the Event stream"
},
"time": {
"type": "number",
"description": "The event time. This maybe different than the timestamps on each of the data entries"
},
"uid": {
"type": "string",
"description": "Globally unique identifier for this Event"
}
},
"required": [
"uid",
"data",
"time",
"descriptor",
"seq_num"
],
"additionalProperties": false,
"type": "object",
"title": "event",
"description": "Document to record a quanta of collected data"
}
Loading