Where can I (should I) add a temp logical in LFRic? #603
Replies: 5 comments 15 replies
-
|
I'm open to opinions here, but my current suggestion would be to put it in the cloud namelist. My reasoning is that whilst the temp_fixes namelist in the UM seemed like a good idea at the time, it's now massive. Personally, I find it very confusing to look at, because it's just a big bucket of fixes to lots of different schemes - there's no grouping or ordering of them, or way of establishing whether a particular fix is relevant to your particular configuration. Putting it in the appropriate science namelist to which the bugfix belongs makes it clear that this is a bugfix to the cloud scheme - it gives it some clear ownership, and enables it to easily be triggered on/off depending on other options that determine whether the fix is actually relevant or used (i.e. in this case whether PC2 is on or off). |
Beta Was this translation helpful? Give feedback.
-
|
I've created an issue #604 to remind us to update the working practices to reflect the UM and LFRic having different systems. I agree that the good intentions behind the UM way have been hard to enforce and implement around this. I'm not sure that having the variables in the namelists for the schemes will make us any more or less likely to retire them - but at least they will be more visible to the scheme owners and I think that is a plus. I think we still want a way to identify these fixes as being different from the other variables in the scheme rather than just a free-for-all. Perhaps a naming scheme that would identify them and make them grep-able? |
Beta Was this translation helpful? Give feedback.
-
|
Steve's guess aligns with my recollection. The intention was that the temp logicals were 'retired' within a year. The thorn in the side being it's not up to code owners to decide to retire them. In fact most code owners tend to run the latest version of their code and so once the bug is fixed, that's the version they run. It's config owners who have top do all the testing and jump thourgh the hoops to determine that the 'fix' doesn't negatively effect the output in a way that can't subsequently be tuned out, and do the long hard work of that tuning. Config owners have no real motivation to do this because it's a lot of work, to get an answer as similar as possible to the one they've already got. temp logicals was an attempt to bring a 'stick' to the discussion to providfe motivation, by making it easier for the technical maintainers (i.e. us) to see the tech debt and nag the config owners into action. I think that in order to get rid of such switches, you have to bite the bullet and say they get physically retired (the code is removed) when the next op model goes to "freeze" - no exceptions. i.e. if you still want to run an old scientific model on a newer release of the code, you either have to backport the 'bug' in a branch in your config or re-tune to as close as possible to get the desired answer. I would be slightly against loosing the switches in the scheme namelists as that's ju7st sweeping them under the carpet. But I can't see a viable, acceptable alternative to achieve the aim temmp logicals set out to achieve. |
Beta Was this translation helpful? Give feedback.
-
|
Yes, I agree we still do want some way of tagging and identifying them... If we were to put them in the science namelists, then perhaps a naming convention something like "temp_fix_xxx" ? That should make them distinct, easily identifiable and searchable. Alternatively, if we were to keep the temp fixes namelist, then equally I think we should have a naming convention something like "cloud_xxx", i.e. something that identifies clearly the scheme to which the fix belongs - this is my main bugbear with the UM system, that it isn't quickly obvious from looking at the namelist who Roddy's bit stick should be aimed at. Either having them in a scheme namelist, named "temp_fix", or having a temp_fix namelist with them named by scheme name satisfies both - it groups them together and clearly identifies their owner. The other key requirement that the UM doesn't adhere to is the metadata triggering being correct - there are items in the temp fixes namelist which don't get trigger ignored when the scheme or feature they pertain to is turned off. I think it's easier to get this triggering right if the switch is in the same namelist as the thing that triggers it, but in principle it should work either way - it just needs to be done. |
Beta Was this translation helpful? Give feedback.
-
|
I just talked to Yash and we agreed it could be something that is discussed at the next LFRic Apps Governance meeting. While that doesn't answer the question above, Yash thought the idea of managing it with a GitHub project (kanban) board was reasonable and should ensure the temporary logicals are not forgotten whatever they are named. A meaningful name, perhaps with reference to the PR in the metadata and code could be useful in identifying items to people reading the code. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi all,
I have a minor bug-fix that I want to lodge in lfric_apps, affecting the PC2 cloud-scheme (the final item in the bullet-list on this issue page: MetOffice/lfric_apps#243). I think in the past it would've been said, if it clearly fixes a bug, just change the code without using any switches as noone will mind a KGO-change for that. But as we get ever-closer to having a frozen and highly-tuned LFRic GC6, I'm guessing that's no-longer the case? In the UM I always ended up having to lodge cloud-scheme bug-fixes under "temporary logicals", because they usually cause a small change in cloud radiative forcing (which is something that has to be finely tuned in the climate model and so mustn't be changed in a frozen configuration).
What's the process for lodging this sort of bug-fix in lfric_apps? I've found the old UM
science_fixes_modstill exists in lfric_apps, but could be retired as currentlyum_physics_initjust sets the relevant logicals to true; none of them are in a namelist. Should I just add a switch to toggle on/off the bug in the LFRic cloud namelist? Or does lfric_apps have its own equivalent to temp logicals somewhere that I've missed?Cheers!
Mike
Beta Was this translation helpful? Give feedback.
All reactions