Introduce aerosol chemistry validation and parser support#282
Conversation
Co-authored-by: Kyle Shores <kyle.shores44@gmail.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #282 +/- ##
==========================================
- Coverage 88.96% 87.65% -1.32%
==========================================
Files 39 41 +2
Lines 1949 2478 +529
==========================================
+ Hits 1734 2172 +438
- Misses 215 306 +91
🚀 New features to boost your workflow:
|
K20shores
left a comment
There was a problem hiding this comment.
A couple of comments, but nothing that should hold up a merge. There's only one comment that wouldn't be addressed by a future issue anyway. If you like the way things look now, I'm happy to accept it
| // Uses the same ValidateSemantics engine as ValidateGasModel, but with | ||
| // YAML-derived input so errors include source locations. |
There was a problem hiding this comment.
ValidateGasModel also includes line information because we have the semantic reference inputs, which I feel we should also add for aerosols
There was a problem hiding this comment.
The gas model can store them in a flat array without relationship information unlike aerosol.
There was a problem hiding this comment.
I'm not sure I follow what you mean here
There was a problem hiding this comment.
Its the discussion we had previously. Aerosol validation requires relationship information to determine which species/solvent belong to which phases, and so on, in order to perform the validation checks.
Gas-phase model can find this information in a flat array, which is implemented in semantic structs to locate where the errors are.
|
Hi @smeechncar, @vweeks, |
This PR:
Mechanism#271Notes:
Validatefunction intoValidateGasModeland introduced a separateValidateAerosolModel.During aerosol validation, the relationship between phases and species(eg. condensed phase and species, gas phase and species, solvent, molecular weight, density ) cannot be expressed in the current
semantics::Inputbecause the required relationship information is lost during flattening. It does not preserve which species belongs to which phase.The intermediate type that I tried to introduced
AerosolProcessRefalso loses the structure by dropping the association between a specific species and its phase context.The current aerosol validation cannot preserve the error locations for the reasons above. This will be addressed in #284