Summary: | example netcdf file complains "You cannot load this much data" | ||
---|---|---|---|
Product: | [Applications] kst | Reporter: | Timo Lindfors <timo.lindfors> |
Component: | datasources | Assignee: | kst |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | arwalker |
Priority: | NOR | ||
Version: | 1.7.0 | ||
Target Milestone: | --- | ||
Platform: | Debian unstable | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | netcdf testcase to reproduce the bug |
Description
Timo Lindfors
2010-06-02 16:11:21 UTC
Created attachment 47611 [details]
netcdf testcase to reproduce the bug
Hi Timo, just my first idea: in kst1, the netcdf datasource does not properly check for dimensions. It can load only vectors, but shows all types of variables, and it is possible that the computation of the number of available samples gives a completely wrong number. But it needs to be investigated a bit more to make sure. You could also try to use a recent kst2 snapshot to see how it behaves there. A couple of days ago the netcdf datasource for kst2 has been substantially improved. It is not 100% done, but may work better. You can find the links and info on the kst mailing list if you need support for that. From what I understand of netcdf only the lon and lat fields actually have data, all the rest are empty. The correct solution would seem to be to remove the empty vectors from the field list - so that the user cannot ask for them to be plotted. I have tried a patch for this in 1.10.0-devel which appears to achieve the desired effect. Let me know if there is any reason not to take this approach. SVN commit 1133924 by arwalker: BUG:240475 return 0 for the samplesForFrame for any empty field. This effectively creates a vector with a single element with a NaN value. This fixes the problem described in this bug report for the kst 1.10 development branch. M +10 -0 netcdf.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1133924 Thank you! I can confirm that after I apply http://websvn.kde.org/branches/extragear/kde3/graphics/kst/src/datasources/netcdf/netcdf.cpp?r1=826410&r2=1133924&pathrev=1133924&view=patch I can successfully read testcase1.netcdf. The vectors that are not in use just show a single nan value. |