process_sidecar_data¶
- astro_metadata_translator.indexing.process_sidecar_data(content: MutableMapping[str, Any]) ObservationInfo | MutableMapping[str, Any] ¶
- astro_metadata_translator.indexing.process_sidecar_data(content: MutableMapping[str, Any], force_metadata: Literal[True]) MutableMapping[str, Any]
- astro_metadata_translator.indexing.process_sidecar_data(content: MutableMapping[str, Any], force_metadata: Literal[False]) ObservationInfo | MutableMapping[str, Any]
Process the content read from a JSON sidecar file.
- Parameters:
- content
dict
Data structure stored in JSON sidecar file converted to simple python form.
- force_metadata
bool
, optional By default the content returned will match the original form that was used for the sidecar. If this parameter is
True
a sidecar ofObservationInfo
will be returned as if it was simple dict content.
- content
- Returns:
- info
ObservationInfo
ordict
of [str
,Any
] If the sidecar file referred to
ObservationInfo
this will return anObservationInfo
, otherwise adict
will be returned. This can be overridden using theforce_metadata
parameter in which case adict
will always be returned.
- info