Skip to content

Commit 416171d

Browse files
authored
Merge pull request #81 from lmichel/shape-serialization
Shape serialization
2 parents 8bca0bc + dd670db commit 416171d

29 files changed

+529
-470
lines changed

README.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ The MANGO model proposes a flexible way to expose data related to astronomical s
1010

1111
# Document Building
1212

13+
## Why such a Complex Workflow?
14+
1315
The process of creating the document is a bit complex due to the following facts:
1416

1517
- The model is maintained with Modelio which does not support any version control.
@@ -22,10 +24,27 @@ The process of creating the document is a bit complex due to the following facts
2224
this must be corrected to have a consistent table of content
2325

2426
This process is achieved by scripts located in `utils`. Please read `utils/README.rst`.
25-
2627
If you want to contribute, please have a look at this workflow or ask the editor.
2728
This will prevent your work to be overridden by some script.
2829

30+
## How to Contribute Anyway
31+
32+
- Install `mivot-validator`in your favorite virtual environment
33+
- Modify the description of some model elements (section 3-11 at the time of writing)
34+
- go into `./vo-dml/desc`
35+
- edit the file you want to update
36+
- go into `utils`
37+
- run `./buildDoc.bash`
38+
- Modify the plain text (section out of 3-11 at the time of writing)
39+
- go into `./doc
40+
- edit `MANGO.tex` or `tap.tex`, those files are never overridden.
41+
- go into `utils`
42+
- run `./buildDoc.bash`
43+
- Modify the model itself
44+
- ask the editor with an issue
45+
46+
If you want to contribute, please have a look at this workflow or ask the editor.
47+
2948
# PDF preview
3049

3150
The PDF preview can be seen [here](https://github.com/ivoa-std/MANGO/releases/download/auto-pdf-preview/MANGO-draft.pdf) thanks to the ADQL team who has written a workflow generating it automatically.

doc/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ DOCNAME = MANGO
77
DOCVERSION = 0.1
88

99
# Publication date, ISO format; update manually for "releases"
10-
DOCDATE = 2025-02-22
10+
DOCDATE = 2025-03-06
1111

1212
# What is it you're writing: NOTE, WD, PR, REC, PEN, or EN
1313
DOCTYPE = WD

doc/ivoatexmeta.tex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
% GENERATED FILE -- edit this in the Makefile
22
\newcommand{\ivoaDocversion}{0.1}
3-
\newcommand{\ivoaDocdate}{2025-02-22}
4-
\newcommand{\ivoaDocdatecode}{20250222}
3+
\newcommand{\ivoaDocdate}{2025-03-06}
4+
\newcommand{\ivoaDocdatecode}{20250306}
55
\newcommand{\ivoaDoctype}{WD}
66
\newcommand{\ivoaDocname}{MANGO}
77
\renewcommand{\ivoaBaseURL}{https://www.ivoa.net/documents/MANGO}

doc/model.tex

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,7 @@ \section{Model: mango }
413413

414414
\subsection{Shape}
415415
\label{sect:Shape}
416-
Description of the spatial extension of the MANGO object (for e.g. dust clouds)
416+
Description of the spatial extent of the MANGO object (e.g. for dust clouds). Shape is serialized as a string. \begin{itemize} \item The supported serialization modes are listed in the \texttt{ShapeSerialization} enumeration. \item If the space coordinate system is not embedded in the serialization mode, it can be defined by the \texttt{spaceSys} reference. \end{itemize}
417417

418418
\subsubsection{Shape.shape}
419419
\textbf{vodml-id: Shape.shape} \newline
@@ -425,7 +425,7 @@ \section{Model: mango }
425425
\textbf{vodml-id: Shape.serialization} \newline
426426
\textbf{type: \hyperref[sect:ShapeSerialization]{mango:ShapeSerialization}} \newline
427427
\textbf{multiplicity: 1} \newline
428-
Serialization mode of the spatial extension of the MANGO entity
428+
Serialization mode of the spatial extension of the \texttt{MangoObject} \newline
429429

430430
\subsubsection{Shape.spaceSys}
431431
\textbf{vodml-id: Shape.spaceSys} \newline
@@ -501,12 +501,12 @@ \section{Model: mango }
501501
\small
502502
\begin{itemize}
503503

504-
\item[\textbf{MOC}]: \textbf{vodml-id:} ShapeSerialization.MOC \newline
505-
\textbf{description:} Label indicating that the shape has been serialized as a S-MOC
506-
\item[\textbf{STCS}]: \textbf{vodml-id:} ShapeSerialization.STCS \newline
507-
\textbf{description:} Label indicating that the shape has been serialized as a STC-S \citep{2007ivoa.spec.1030R} string
504+
\item[\textbf{SMOC}]: \textbf{vodml-id:} ShapeSerialization.SMOC \newline
505+
\textbf{description:} Label indicating that the shape has been serialized as a SMOC \citep{2022ivoa.spec.0727F}. SMOC should be in equatorial ICRS. This overrides the attached space coordinate system (\texttt{spaceSys} reference). When using this serialisation, \texttt{spaceSys} can be ignored.
506+
\item[\textbf{STC-S}]: \textbf{vodml-id:} ShapeSerialization.STC-S \newline
507+
\textbf{description:} Label indicating that the shape has been serialized as a STC-S string (see \url{https://www.ivoa.net/documents/STC-S/20130917/index.html}). SMOC should be in equatorial ICRS. This overrides the attached space coordinate system (\texttt{spaceSys} reference). When using this serialisation, \texttt{spaceSys} can be ignored.
508508
\item[\textbf{POLYGON}]: \textbf{vodml-id:} ShapeSerialization.POLYGON \newline
509-
\textbf{description:} Label indicating that the shape has been serialized as a polygon (cf xtypes)
509+
\textbf{description:} Label indicating that the shape has been serialized as a polygon as defined in \cite{2017ivoa.spec.0517D} section 3.3.7. Using the polygon serialization requires the space coordinate system to be defined.
510510
\end{itemize}
511511
\normalsize
512512

doc/model_toc.tex

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ \section{Other Properties}
478478

479479
\subsection{Shape}
480480
\label{sect:Shape}
481-
Description of the spatial extension of the MANGO object (for e.g. dust clouds)
481+
Description of the spatial extent of the MANGO object (e.g. for dust clouds). Shape is serialized as a string. \begin{itemize} \item The supported serialization modes are listed in the \texttt{ShapeSerialization} enumeration. \item If the space coordinate system is not embedded in the serialization mode, it can be defined by the \texttt{spaceSys} reference. \end{itemize}
482482

483483
\subsubsection{Shape.shape}
484484
\textbf{vodml-id: Shape.shape} \newline
@@ -490,7 +490,7 @@ \section{Other Properties}
490490
\textbf{vodml-id: Shape.serialization} \newline
491491
\textbf{type: \hyperref[sect:ShapeSerialization]{mango:ShapeSerialization}} \newline
492492
\textbf{multiplicity: 1} \newline
493-
Serialization mode of the spatial extension of the MANGO entity
493+
Serialization mode of the spatial extension of the \texttt{MangoObject} \newline
494494

495495
\subsubsection{Shape.spaceSys}
496496
\textbf{vodml-id: Shape.spaceSys} \newline
@@ -507,12 +507,12 @@ \section{Other Properties}
507507
\vspace{-\parsep}
508508
\small
509509
\begin{itemize}
510-
\item[\textbf{MOC}]: \textbf{vodml-id:} ShapeSerialization.MOC \newline
511-
\textbf{description:} Label indicating that the shape has been serialized as a S-MOC
512-
\item[\textbf{STCS}]: \textbf{vodml-id:} ShapeSerialization.STCS \newline
513-
\textbf{description:} Label indicating that the shape has been serialized as a STC-S \citep{2007ivoa.spec.1030R} string
510+
\item[\textbf{SMOC}]: \textbf{vodml-id:} ShapeSerialization.SMOC \newline
511+
\textbf{description:} Label indicating that the shape has been serialized as a SMOC \citep{2022ivoa.spec.0727F}. SMOC should be in equatorial ICRS. This overrides the attached space coordinate system (\texttt{spaceSys} reference). When using this serialisation, \texttt{spaceSys} can be ignored.
512+
\item[\textbf{STC-S}]: \textbf{vodml-id:} ShapeSerialization.STC-S \newline
513+
\textbf{description:} Label indicating that the shape has been serialized as a STC-S string (see \url{https://www.ivoa.net/documents/STC-S/20130917/index.html}). SMOC should be in equatorial ICRS. This overrides the attached space coordinate system (\texttt{spaceSys} reference). When using this serialisation, \texttt{spaceSys} can be ignored.
514514
\item[\textbf{POLYGON}]: \textbf{vodml-id:} ShapeSerialization.POLYGON \newline
515-
\textbf{description:} Label indicating that the shape has been serialized as a polygon (cf xtypes)
515+
\textbf{description:} Label indicating that the shape has been serialized as a polygon as defined in \cite{2017ivoa.spec.0517D} section 3.3.7. Using the polygon serialization requires the space coordinate system to be defined.
516516
\end{itemize}
517517
\normalsize
518518

mivot/mango/mango.EpochPosition.xml

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,20 @@
11
<INSTANCE dmrole="" dmtype="mango:EpochPosition">
2-
<!-- This class (fig \ref{fig:EpochPosition}) is a view of \texttt{Astronomical Coordinates and Coordinate Systems}
3-
\citep{2022ivoa.specQ1004R} components that have been combined to form a consistent description of
4-
the position of an object moving in time.
2+
<!-- This class (fig \ref{fig:EpochPosition}) is a flattened view of objects/concepts from the
3+
Astronomical Measurements Model \citep{2022ivoa.specQ1004R} that have been put together
4+
to form a consistent description of the position of an object moving over time.
5+
It consists of a celestial position, a proper motion, a radial velocity and a parallax and their associated
6+
errors encapsulated into the \texttt{EpochPositionErrors} class.
7+
The values of these properties are pulled from the underlying Astronomical Coordinates and Coordinate Systems
8+
model \citep{2022ivoa.spec.1004R}
9+
10+
At a high level the properties map as follows:
11+
\begin{itemize}
12+
\item celestial position -> \texttt{meas:Position}
13+
\item proper motion -> \texttt{meas:ProperMotion}
14+
\item radial velocity -> \texttt{meas.Velocity}
15+
\item parallax -> no suitable counterpart at this time
16+
\end{itemize}
517
6-
It consists of a celestial position, a proper motion, a radial velocity and a parallax.
718
819
All components use the same coordinate systems for both time and space coordinates.
920
@@ -52,7 +63,7 @@ In some cases the errors might conflict with the correlations:
5263
<!-- Put here a concrete INSTANCE of error.PropertyError or left blank -->
5364
<INSTANCE dmrole="mango:EpochPositionErrors.properMotion" dmtype="mango:error.PropertyError"/>
5465
<!-- Put here a concrete INSTANCE of error.PropertyError or left blank -->
55-
<INSTANCE dmrole="mango:EpochPositionErrors.Position" dmtype="mango:error.PropertyError"/>
66+
<INSTANCE dmrole="mango:EpochPositionErrors.position" dmtype="mango:error.PropertyError"/>
5667
</INSTANCE>
5768
<INSTANCE dmrole="mango:EpochPosition.correlations" dmtype="mango:EpochPositionCorrelations">
5869
<!-- Class holder for the correlation coefficients between the \texttt{EpochPosition} components." -->

mivot/mango/mango.EpochPositionErrors.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@
77
<!-- Put here a concrete INSTANCE of error.PropertyError or left blank -->
88
<INSTANCE dmrole="mango:EpochPositionErrors.properMotion" dmtype="mango:error.PropertyError"/>
99
<!-- Put here a concrete INSTANCE of error.PropertyError or left blank -->
10-
<INSTANCE dmrole="mango:EpochPositionErrors.Position" dmtype="mango:error.PropertyError"/>
10+
<INSTANCE dmrole="mango:EpochPositionErrors.position" dmtype="mango:error.PropertyError"/>
1111
</INSTANCE>

mivot/mango/mango.MangoObject.xml

Lines changed: 30 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -59,37 +59,38 @@ This class specifies both type and role of the property, and hosts the property
5959
<ATTRIBUTE dmrole="mango:Property.description" dmtype="ivoa:string" ref="@@@@@" value=""/>
6060
</INSTANCE>
6161
</COLLECTION>
62-
<INSTANCE dmrole="mango:MangoObject.queryOrigin" dmtype="mango:dataorigin.QueryOrigin">
63-
<!-- Description of the query the MANGO instance results from." -->
64-
<ATTRIBUTE dmrole="mango:dataorigin.QueryOrigin.publisher" dmtype="ivoa:string" ref="@@@@@" value=""/>
65-
<ATTRIBUTE dmrole="mango:dataorigin.QueryOrigin.server_software" dmtype="ivoa:string" ref="@@@@@" value=""/>
66-
<ATTRIBUTE dmrole="mango:dataorigin.QueryOrigin.service_protocol" dmtype="ivoa:string" ref="@@@@@" value=""/>
67-
<ATTRIBUTE dmrole="mango:dataorigin.QueryOrigin.request" dmtype="ivoa:string" ref="@@@@@" value=""/>
68-
<ATTRIBUTE dmrole="mango:dataorigin.QueryOrigin.request_date" dmtype="ivoa:string" ref="@@@@@" value=""/>
69-
<ATTRIBUTE dmrole="mango:dataorigin.QueryOrigin.query" dmtype="ivoa:string" ref="@@@@@" value=""/>
70-
<ATTRIBUTE dmrole="mango:dataorigin.QueryOrigin.contact" dmtype="ivoa:string" ref="@@@@@" value=""/>
71-
<COLLECTION dmrole="mango:dataorigin.QueryOrigin.dataOrigin">
72-
<INSTANCE dmrole="mango:dataorigin.QueryOrigin.dataOrigin" dmtype="mango:dataorigin.DataOrigin">
73-
<!-- Class representing the origin of the data following the DCP note" -->
74-
<ATTRIBUTE dmrole="mango:dataorigin.DataOrigin.ivoid" dmtype="ivoa:string" ref="@@@@@" value=""/>
75-
<ATTRIBUTE dmrole="mango:dataorigin.DataOrigin.reference_url" dmtype="ivoa:string" ref="@@@@@" value=""/>
76-
<ATTRIBUTE dmrole="mango:dataorigin.DataOrigin.resource_version" dmtype="ivoa:string" ref="@@@@@" value=""/>
77-
<COLLECTION dmrole="mango:dataorigin.DataOrigin.creators">
62+
<INSTANCE dmrole="mango:MangoObject.queryOrigin" dmtype="mango:origin.QueryOrigin">
63+
<!-- Description of the query the \texttt{MangoObject} results from." -->
64+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.publisher" dmtype="ivoa:string" ref="@@@@@" value=""/>
65+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.server_software" dmtype="ivoa:string" ref="@@@@@" value=""/>
66+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.service_protocol" dmtype="ivoa:string" ref="@@@@@" value=""/>
67+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.request" dmtype="ivoa:string" ref="@@@@@" value=""/>
68+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.request_date" dmtype="ivoa:string" ref="@@@@@" value=""/>
69+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.query" dmtype="ivoa:string" ref="@@@@@" value=""/>
70+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.contact" dmtype="ivoa:string" ref="@@@@@" value=""/>
71+
<ATTRIBUTE dmrole="mango:origin.QueryOrigin.ivoid" dmtype="ivoa:string" ref="@@@@@" value=""/>
72+
<COLLECTION dmrole="mango:origin.QueryOrigin.dataOrigin">
73+
<INSTANCE dmrole="mango:origin.QueryOrigin.dataOrigin" dmtype="mango:origin.DataOrigin">
74+
<!-- Class representing the description of the origin of the queried dataset.
75+
" -->
76+
<ATTRIBUTE dmrole="mango:origin.DataOrigin.ivoid" dmtype="ivoa:string" ref="@@@@@" value=""/>
77+
<ATTRIBUTE dmrole="mango:origin.DataOrigin.reference_url" dmtype="ivoa:string" ref="@@@@@" value=""/>
78+
<ATTRIBUTE dmrole="mango:origin.DataOrigin.resource_version" dmtype="ivoa:string" ref="@@@@@" value=""/>
79+
<COLLECTION dmrole="mango:origin.DataOrigin.creators">
7880
</COLLECTION>
79-
<ATTRIBUTE dmrole="mango:dataorigin.DataOrigin.cites" dmtype="ivoa:string" ref="@@@@@" value=""/>
80-
<COLLECTION dmrole="mango:dataorigin.DataOrigin.is_derived_from">
81+
<ATTRIBUTE dmrole="mango:origin.DataOrigin.cites" dmtype="ivoa:string" ref="@@@@@" value=""/>
82+
<COLLECTION dmrole="mango:origin.DataOrigin.is_derived_from">
8183
</COLLECTION>
82-
<ATTRIBUTE dmrole="mango:dataorigin.DataOrigin.original_date" dmtype="ivoa:string" ref="@@@@@" value=""/>
83-
<INSTANCE dmrole="mango:dataorigin.DataOrigin.article" dmtype="mango:dataorigin.Article">
84-
<!-- Reference article for the MANGO entity" -->
85-
<ATTRIBUTE dmrole="mango:dataorigin.Article.editor" dmtype="ivoa:string" ref="@@@@@" value=""/>
86-
<ATTRIBUTE dmrole="mango:dataorigin.Article.code" dmtype="ivoa:string" ref="@@@@@" value=""/>
87-
</INSTANCE>
88-
<INSTANCE dmrole="mango:dataorigin.DataOrigin.license" dmtype="mango:dataorigin.License">
89-
<!-- Place holder for the license covering the MANGO instance" -->
90-
<ATTRIBUTE dmrole="mango:dataorigin.License.rights_uri" dmtype="ivoa:string" ref="@@@@@" value=""/>
91-
<ATTRIBUTE dmrole="mango:dataorigin.License.rights" dmtype="ivoa:string" ref="@@@@@" value=""/>
92-
</INSTANCE>
84+
<ATTRIBUTE dmrole="mango:origin.DataOrigin.original_date" dmtype="ivoa:string" ref="@@@@@" value=""/>
85+
<ATTRIBUTE dmrole="mango:origin.DataOrigin.rights" dmtype="ivoa:string" ref="@@@@@" value=""/>
86+
<ATTRIBUTE dmrole="mango:origin.DataOrigin.rights_uri" dmtype="ivoa:string" ref="@@@@@" value=""/>
87+
<COLLECTION dmrole="mango:origin.DataOrigin.articles">
88+
<INSTANCE dmrole="mango:origin.DataOrigin.articles" dmtype="mango:origin.Article">
89+
<!-- Reference article for the \texttt{MangoObject}" -->
90+
<ATTRIBUTE dmrole="mango:origin.Article.editor" dmtype="ivoa:string" ref="@@@@@" value=""/>
91+
<ATTRIBUTE dmrole="mango:origin.Article.identifier" dmtype="ivoa:string" ref="@@@@@" value=""/>
92+
</INSTANCE>
93+
</COLLECTION>
9394
</INSTANCE>
9495
</COLLECTION>
9596
</INSTANCE>

mivot/mango/mango.PhysicalProperty.xml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
<INSTANCE dmrole="" dmtype="mango:PhysicalProperty">
2-
<!-- Place holder for any quantity that can be hold by measure classes as defined in the
3-
\texttt{Astronomical Measurements Model}." -->
2+
<!-- Holder for any quantity that can be modeled by measure classes (Position, Time , Velocity, Polarization, ProperMotion, GenericMeasure)
3+
as defined in the \texttt{Astronomical Measurements Model}.
4+
5+
" -->
46
<INSTANCE dmrole="mango:Property.semantics" dmtype="mango:VocabularyTerm">
57
<!-- Class holder for a term of a standardized vocabulary that applies to a property." -->
68
<ATTRIBUTE dmrole="mango:VocabularyTerm.uri" dmtype="ivoa:string" ref="@@@@@" value=""/>

mivot/mango/mango.Shape.xml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
<INSTANCE dmrole="" dmtype="mango:Shape">
2-
<!-- Description of the spatial extension of the MANGO object (for e.g. dust clouds)" -->
2+
<!-- Description of the spatial extent of the MANGO object (e.g. for dust clouds).
3+
Shape is serialized as a string.
4+
\begin{itemize}
5+
\item The supported serialization modes are listed in the \texttt{ShapeSerialization} enumeration.
6+
\item If the space coordinate system is not embedded in the serialization mode, it can be defined by the \texttt{spaceSys} reference.
7+
\end{itemize}" -->
38
<INSTANCE dmrole="mango:Property.semantics" dmtype="mango:VocabularyTerm">
49
<!-- Class holder for a term of a standardized vocabulary that applies to a property." -->
510
<ATTRIBUTE dmrole="mango:VocabularyTerm.uri" dmtype="ivoa:string" ref="@@@@@" value=""/>
@@ -8,7 +13,7 @@
813
<ATTRIBUTE dmrole="mango:Property.description" dmtype="ivoa:string" ref="@@@@@" value=""/>
914
<ATTRIBUTE dmrole="mango:Shape.shape" dmtype="ivoa:string" ref="@@@@@" value=""/>
1015
<!-- Enumeration of the supported serialization modes for the shapes -->
11-
<!-- Enumeration datatype: supported values are MOC STCS POLYGON -->
12-
<ATTRIBUTE dmrole="mango:Shape.serialization" dmtype="mango:ShapeSerialization" value="OneOf MOC STCS POLYGON "/>
16+
<!-- Enumeration datatype: supported values are SMOC STC-S POLYGON -->
17+
<ATTRIBUTE dmrole="mango:Shape.serialization" dmtype="mango:ShapeSerialization" value="OneOf SMOC STC-S POLYGON "/>
1318
<INSTANCE dmrole="mango:Shape.spaceSys" dmtype="coords:SpaceSys"/>
1419
</INSTANCE>

0 commit comments

Comments
 (0)