celeritas icon indicating copy to clipboard operation
celeritas copied to clipboard

Add optical absorption model with imported data

Open hhollenb opened this issue 1 year ago • 1 comments

The base optical Model class with AbsorptionModel as an example case. ImportedModels is a list of ImportOpticalModels with a map for built-in model classes to their imported identifier, and can be built directly or from imported data with a ModelImporter (included in a later PR). ImportedModelAdapter can then be used by models to access their MFP tables.

MFP tables are built with detail::MfpBuilder which internally handles the grid IDs that a model builds. It should probably be refactored when we refactor the rest of the grid builders.

For testing I created a MockImportData class to handle a bunch of common mock data and functions that the model classes use. I find that it makes writing the tests easy and fairly consistent, but could probably use a good critique.

hhollenb avatar Oct 03 '24 20:10 hhollenb

Test summary

 3 345 files   5 161 suites   3m 56s :stopwatch:  1 548 tests  1 520 :white_check_mark: 28 :zzz: 0 :x: 17 138 runs  17 075 :white_check_mark: 63 :zzz: 0 :x:

Results for commit f5d3329f.

:recycle: This comment has been updated with latest results.

github-actions[bot] avatar Oct 03 '24 20:10 github-actions[bot]

Sorry for the delay @hhollenb --this looks great at first glance, I'll go over it in detail first thing tomorrow!

amandalund avatar Oct 11 '24 02:10 amandalund

Ack sorry I clicked merge before I read you comment. I'll setup the Rayleigh scattering PR which will be mostly the same and can be used for some further review.

hhollenb avatar Oct 18 '24 23:10 hhollenb

I didn't even realize you had permissions to merge 🤔

sethrj avatar Oct 19 '24 06:10 sethrj