Closed hloewe closed 2 years ago
Fixed. The detrending was re-added in v1.0.1.
Values of δ are smaller (<0.1) following the introduction of detrending . Is np.correlate working as expected? Looking back on Matlab code from Martin/Henning lab I see that unbiased scaling was used with xcorr:
[C_f,d] = xcorr(detrend(f_z-c1),detrend(f_z-c1),'unbiased');
I can't find documentation on normalization of numpy's correlate but the result of the two-point function is sufficiently different to push δ downwards. For us, this is leading to unrealistic density estimates, where as using the windowed force as-is, produces an expected result. Below is an example completed on first year sea ice with an extremely dense wind slab underlain with depth hoar:
The red dots are field measured density behind the SMP profile. Differences in λ and L produce the higher density. I've confirmed this behavior on all profiles from our SMP unit and have attached the file for reference. Tuning the microstructure coefficients with OLS eases this issue but I'd like to understand whats going on here and establish QA flags for valid δ, λ and L.
hi josh, thanks a lot for the feedback through this channel. ill check and come back to it. cheers
hi josh,
part 1 of the answer: i am sure that your observation is not related to differences in the use of the correlation function to compute the parameters. The comparison of delta, L, f0 computed from v1.0.1 (including the detrending and np.correlate) with the old matlab stuff applied to the data you sent: (all normalized by the mean to make them fit into one scatter plot)
from that i conclude that it is not a software issue. which brings me to
part 2 of the answer: your observation of disagreement between your red dots and smp-derived density is likely an issue with the parametrization from proksch et al 2015. and imho it is mainly related to the fact that the parameterizations from proksch et al 2015 were derived from measurements with an SMP device version 2, while in the present version 4 some electronic components had to be replaced. this had an impact on force correlations at the smallest scales, i.e. the parameter delta from the shot-noise model. as a remedy, we have recently derived a re-calibration of the proksch et al 2015 statistical model that is applicable to smp devices version 4. its not yet published, but a sneak preview on the comparison to many cutter measurements reveals exactly the trend you observed for your three measurements:
in short: applying the proksch et al 2015 parametrization, on the parameters delta, L, f0, computed with the algorithm including the detrending, from measurements with smp version 4 generally seems to overestimate the density when compared to cutter measurements in the high density regime your are looking at.
hope that helps cheers, henning
Thanks for looking into this Henning, I really appreciate it. It'll be interesting to compare your coefficients with our snow on sea ice analysis. Using an OLS approach we were able to retrieve density with an RMSE of 40 kg m-3 and R2 of 0.7. Happy to share more on the approach in other channels if it is of interest.
your're welcome, josh. and good to see the consistency. just to finish the topic here (to be clear again: its not a software issue anymore, its a scientific one): we have already implemented the new statistical model in the devel branch of snowmicropyn (cf calonne2018.py) to allow for offline feedback. disclaimer: neither published yet, nor in the official software package, real support for that presently not feasible. cheers
Hi,
your coefficient sets have been added (and, of course, cited), thanks for your work! Recent changes leading up to the new v1.1.0 make it as easy as can be to add new parameterizations in the future, see this comment.
I think from a technical standpoint the requirements are fulfilled now so I'm closing this, but feel free to reopen if issues come up.
In snowmicropyn v1.0.0 the calculation of density and ssa yields strange values since the calculation of the parameters of the underlying penetration-model was carried as originally published in (Löwe and van Herwijnen, CRST, 2012) and not as employed in (Proksch et al, JGR, 2015): The latter uses an additional de-trending of the signal prior to the calculation of the force correlation function.