makeObservationInfo

astro_metadata_translator.makeObservationInfo(*, extensions: Optional[Dict[str, PropertyDefinition]] = None, **kwargs: Any) ObservationInfo

Construct an ObservationInfo from the supplied parameters.

Parameters:
extensionsdict [str: PropertyDefinition], optional

Optional extension definitions, indexed by extension name (without the ext_ prefix, which will be added by ObservationInfo).

**kwargs

Name-value pairs for any properties to be set. In the case of extension properties, the names should include the ext_ prefix.

Raises:
KeyError

Raised if a supplied parameter key is not a known property.

TypeError

Raised if a supplied value does not match the expected type of the property.

Notes

The supplied parameters should use names matching the property. The type of the supplied value will be checked against the property. Any properties not supplied will be assigned a value of None.