Closed ipg-jsc closed 2 months ago
I would favour either the first or the last approach. Having some form of hierarchy makes it easier to find the parameter combination you are looking for. If it is all in one table, your algorithm has to search through all the rows to find the correct parameter.
Let's discuss this in the meeting on 21.08.
Preliminary decisions:
Metadata can be added as normal fields with name-value pairs. As far as I have checked, there are no specific header information possible.
Grouping can be made by using another nesting level.
An example with index of refraction could be:
{
"metadata": {
"material": "Silicon",
"description": "Refractive index data for Silicon with temperature and wavelength dependence",
"units": {
"temperature": "Kelvin",
"wavelength": "nanometers"
}
},
"data": [
{
"temperature": 300,
"measurements": [
{
"wavelength": 500,
"n": 4.292,
"k": 0.0495
},
{
"wavelength": 600,
"n": 3.948,
"k": 0.0203
},
{
"wavelength": 700,
"n": 3.752,
"k": 0.0092
}
]
},
{
"temperature": 400,
"measurements": [
{
"wavelength": 500,
"n": 4.301,
"k": 0.0506
},
{
"wavelength": 600,
"n": 3.957,
"k": 0.0210
},
{
"wavelength": 700,
"n": 3.760,
"k": 0.0097
}
]
}
]
}
Metadata can be added as normal fields with name-value pairs. As far as I have checked, there are no specific header information possible.
But this might lead to people thinking these are changeable parameters. I would like to avoid someone adding a material with temperature in Fahrenheit.
Preliminary decisions:
Preliminary decision (still has to be tested and finally discussed in the group and with ASAM):
Use xomp as a file extension. The 'x' stands for OpenX Standard and 'omp' stands for 'OpenMATERIAL parameter'.
Use a suffix for look-up table files e.g. 'aluminum.xomp' for the main file and 'aluminum_permittivity_permeability.xomp', 'aluminum_brdf.xomp' for auxiliary look-up tables.
Preliminary decision (still has to be tested and finally discussed in the group and with ASAM):
Use xomp as a file extension. The 'x' stands for OpenX Standard and 'omp' stands for 'OpenMATERIAL parameter'.
Use a suffix for look-up table files e.g. 'aluminum.xomp' for the main file and 'aluminum_permittivity_permeability.xomp', 'aluminum_brdf.xomp' for auxiliary look-up tables.
On second thought: It might be easier to use a separate file extension for the look-up tables. The JSON schema validation works by using input files names with wildcards. Since we will have different schemas for the different files, the above example would work for _permittivity_permeability.xomp and _brdf.xomp but when checking the main material file with *.xomp would also apply to the look-up table files.
Just as an example, I will use xomlt as in OpenMATERIAL look-up table as a file extension. @drsftx73 this needs to be discussed in the next meeting.
To make filenames a bit shorter we could use '_emp' (electro-magnetic properties) as a suffix instead of '_permeability_permittivity'.
I added the proposal in the pull request linked above.
I am in favor to use a different file extension for lookup tables as it you will immediately know, what you are dealing with.
Shorten the filenames enhances the readability but the parameters inside are not only EM-properties as it includes temperature, humidity etc.
Shorten the filenames enhances the readability but the parameters inside are not only EM-properties as it includes temperature, humidity etc.
But as far as I see it, wavelength, humidity and temperature are only there to pick the correct EM-properties, right?
as a group we agreed that there should be two different suffixes - xomp and xompt work well. @ClemensLinnhoff - are you good with xompt vs xomplt?
Most measurements are only valid under certain conditions, that have to be stored alongside. The JSON format allows to store that data in many different structures and hierarchies (any combination of arrays and structs possible).
Examples based on the index of refraction:
(Note: BRDF lookups would be another example that could additionally require θin, θout, φout)
Original proposal (special treatment of the wavelength as the lowest level of hierarchy):
Singular data points with explicit mention of each key:
Pure array (meaning of each entry has to derived from the schema)
Treating each condition as separate hierarchy level (will probably lead to deep nesting)
Do we need a hierarchy in our measurement conditions? Could a mandatory order of elements in a flat hierarchy be an alternative?
Do we want a special treatment of certain conditions (as for the wave length in the original proposal)?