-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
EHN: Tdiff Correction for Elevation Data #290
Conversation
@carleyjmartin thank you for adding this - it will be a very useful capability for pydarn. It appears the IDL Davit code was based on the original elevation angle algorithm, which could only handle interferometer offsets in a single direction. Since then a more generalized algorithm has been published which can support interferometer offets in all 3 dimensions (Shepherd [2017]), eg |
@carleyjmartin I updated the code so that we now use the more generalized version developed by Simon. Seems to work on my machine. Can you please test it out? @egthomas Thanks for pointing this out Evan. Can you please help us test this using CV data? I tried to use it for BKS and it seems to be working on a qualitative sense. But it would be great if this can be tested out on a radar where the tdiff parameter is tuned. |
Code looks great, just ran flake8 on it to tidy up the styling. I've tested with my website back end and it works great, the plot outputs when tuning the tdiff look reasonable, but it would be nice to have a scientist to have a test to make sure the results are correct. EDIT: Also merged with current develop below to pull any updates we did on the release for the rest of the branch. |
Thanks @carleyjmartin. I feel a good way to validate the output is by reproducing some of the results presented in previous studies. I can work on it. |
I tried to reproduce Figure 6 from the Ponomarenko et al., 2015 paper as a method of validation (see plot). I think there is agreements in a qualitative sense. |
I have reviewed the codes and compared it with the RST C code and another Python version Shibaji wrote. They look good to me. I have an issue accessing the fitacf data that Bharat tested from my lab computer and thus cannot provide any help on testing it now. |
@bharatreddy Code looks good to me. One quick comment, the 'recalculate_elevation' method takes data(list of dict) and tdiff as inputs. But I recall while working with Pasha, some of SAS radar observation were from back lobe and he requested to input new 'interferometer_offset' position (other than values taken from hwd.dat files) to reevaluate the angles. If you think (might not be in this release, maybe next) can you please include 'interferometer_offset' as an input (tuple) just like tdiff so that it can be used for other back lobe returns [just a suggestion, feel free to ignore]. |
A keyword
:) |
Scope
This pull request includes a new utility to return 'amended elevation' values for different tdiff values.
You can return the entire dmap data structure to use with plotting, or just the new elevation values by using the
overwrite
keyword. In amending the data structure with new values, rather than the plot, you can use the amended elevation in any plot type, not just RTPs.issue: no issue
Approval
Number of approvals: 2, including a code review please
Test
matplotlib version: 3.6.2
Note testers: please indicate what version of matplotlib you are using
Calling the function with overwrite=False (or left off) will return the elevation data only in a dictionary, this output will not work if you put it straight into a plot:
Please test for accuracy, when looking at the same plots made from the DaViT library, it appears to be similar, but I don't know for sure
*Reminder, please check your code is: