-
Notifications
You must be signed in to change notification settings - Fork 36
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
Does not work with GRIB_pi & O fails. v4.2.1706 #40
Comments
It seems that the recently added support for gribV2 breaks this because this changed the physical layout of Seems pretty fragile to rely on these 2 projects to keep their data structures in sync. Should we not minimally add a version number to the data so that weather_routing_pi simply complaints instead of crashing O? |
I tried to fix this (by copying some files from O to this plugin and adding a dummy virtual function and now it no longer crashes. However, it always reports "Failed" as state. How can I debug that further? |
Isn't this fixed by #39 ? |
Pavel, have you made these changes in #39 to the plugin? If so what version of Wx-routing, and where to download? Also what version of Opencpn should we be testing with? |
This is not my project, I am not merging changes from other devs into my clone unless absolutely necessary. |
OK, fine. What should I test? Where the devil is Sean? |
The plugin built with #39 applied. There is no binary for it, you have to build yourself. |
Ok, I guess I can do that, can you tell me which version of OpenCPN to test with? & should I build that too? |
No you don't need to build OpenCPN, you should test against 4.2.1724 released today. |
Ok will test tonight. Thanks. |
I am still making big changes to the plugin which has slowed me down, and haven't had the time or internet to do much. Hopefully today I can. |
I saw that the data sent by grib_pi had a vtable for GribRecord, but the same was missing for GribRecord in weather_routing_pi, which messed up all the data (resulting in SEGV). I "fixed" that by adding a dummy virtual function into GribRecord from weather_routing_pi. Perhaps was caused by compiling one with optimization and the other w/o? Another problem were SEGV caused by accessing non-null but uninitialized BMSbits. I saw that there is also a I would of course be happy to share all of this but while it no longer crashes, I still always get "Failed" when computing a route. BTW: I use the |
Success!!! With pull request #39 merged I can again compute routes w/o any local patches. My earlier problems were caused by stupidly copying the files into the wrong directory. Thanks so much. Now on to get a nice route for the Spinnaker Cup this weekend! |
Sean, before this I git fetched 7 days ago and built and it worked with pr#39 and v4.2.1724. Now I git fetched your repos and built and I get errors.... sorry. Build FAILED. "C:\Users\Rick\Documents\GitHub\o-plugin\s-weather_routing_pi\build\ALL_BUILD.vcxproj" (default tar "C:\Users\Rick\Documents\GitHub\o-plugin\s-weather_routing_pi\build\ALL_BUILD.vcxproj" (default tar
I think I am missing a file in your repos? |
Thank you rick, I have attempted corrections. Sean On 6/1/16, Rick Gleason notifications@github.com wrote:
|
That did the trick. Will advise about running it. Some warnings FYI.. Thank you! Build succeeded. "C:\Users\Rick\Documents\GitHub\o-plugin\s-weather_routing_pi\build\ALL_BUILD.vcxproj" (default tar
|
Sean, these menus for the Boat are looking much better to me!!! I guess we are going to be able to use different polars and establish when to change to a different polar. Thank you for your improvements. I built for v4.2.1724 using opencpn.lib 4.2.1724 is that correct? |
I just tried another GFS and a routing that worked before, set the grib time etc, tried to check that the boat polar was selected, think I selected it and tried compute. ..Failed. I think we must have a separate slot showing the actual boat polar file being used, somewhere after you close the selection of the boat polar in the Configuration file under "Boat" have "Polar File" This would be confirmation to the user that they have a polar selected that is accepted as valid. ... I think it is failing because I have not selected the polar file properly or something.... and I cannot see the full path under "Boat" anyway. PS: I can scroll to see the full path,... and now I seee that "Boat" has You used to have boat parameters which we could enter and polars would be calculated. These parameters were saved in the xml files. The problem was that you would enter the parameters in for your boat, the polar would be generated, (or you could load a polar file *.pol, csv, etc) and you could save the boat file as Yourboat.xml. The the next time you opened up the plugin, it would all be reset back to the startup boat.xml file and you would have to enter your boat's parameters back in again to get a generated polar from the boats parameters. The polar files (.pol, .csv etc) in the correct format could also be used before (and now) but that was a separate method. In the current plugin how do the boat parameters work? perhaps I am not getting this. Maybe we even need checkboxes to direct the program whether to use
I think if I add multiple polars to the "Polars List" I am uncertain what I should do with "Crossover" but I think this is sort of like setting up sail changes or change in sea conditions or something like we had before. This seems to stay blank no matter what I do...? Anyway that's what I get from poking around a bit. Thanks nkiesel and lance that's helpful to know others have similar problem. It certainly is going to be nice to have the interface working as you intend, and we stand ready to help in whatever way possible. I am delighted with the direction you are taking, but need to understand more. |
I tried O from git master branch (b9397b3) together with weather_routing_pi from master branch (0724ae2) on 64bit Debian Sid. Everything compiles and installs. I use the same grib files and configurations I used a week ago. However, now all I get is "Failed". Is there any log I can look at or debug I can enable to find out what happens? I would also be happy to run using gdb if you tell me what to look for. One difference is that last week I was using both compiled without optimization. I could try to do this again and see if this changes things. |
It would be nice if weather_routing reported reasons instead of just On Wed, Jun 1, 2016 at 8:24 AM, Norbert Kiesel notifications@github.com
|
I just compiled both O and WR with debug (using Next step could be a O does not compile in debug mode for me: it gives errors for |
Norbert i'd like to know how to do a bisect. Maybe we could scan the commits? I think youd do a pull request to seans repos for wxroting |
tri.c will die very soon anyway. As for weather routing failing... did you configure the boat properly? Did you load a polar? Do you have valid weather data? Does the polar give boat speeds for the wind speeds from the actualy weather situation? You can post the configuration xml, the boat xml, and any polar files used, as well as grib files, and the issue should be easily reproducible. |
Attached the files, let me know if you need anything else. |
Note that you should do that starting with a clean workspace (i.e. no uncommitted changes). |
I don't have the X_362.pol or the grib you used, but the problem is probably that the polar isn't defined for low enough wind speeds for what the current grib is showing. You could try adding a column of 0 for 0 wind speed or something. This is changed from previous versions... maybe I can add an option to allow extrapolation, but I consider this a feature. |
The polar file already has a row of 0. I added both the polar and the grib in the attached zip file above. I also attached the polar (renamed to X_362.pol.txt) once more. Thanks for looking into this! |
I tried it out and the routing works fine. Do you have the latest git? Sean On 6/1/16, Norbert Kiesel notifications@github.com wrote:
|
I use b9397b3 from O master branch, plus my little patch to add 3 So yes, latest git. And this worked a week ago (with a slightly older version). Am willing to debug or try patches if that helps. |
Wow, you guys have blown past my skills. |
I'll try some of these again but since I have wxrouting running in debug mode msvc++ why can't I set some break points to determine where it fails? Is this a picky msvc++ causing the problem? Where can I put a break in the main calculation loop (isobars) to be certain the loop is working. |
Maybe it would be quicker to do a git bisect and test? Never done that, but I should learn how. What do you think Sean? |
On 6/16/16, mbouyer notifications@github.com wrote:
I tried with your grib and it works, but not with the wrong config. If the timestep is above 30 minutes, then the max diverted course The best thing in this case is to reduce the timestep to 10 minutes. I cannot print a simple message explaining this to the user because it Sean
|
On Thu, Jun 16, 2016 at 05:37:50AM -0700, seandepagnier wrote:
I tried changing these parameters but it still doesn't work. I'll try to debug Manuel Bouyer bouyer@antioche.eu.org NetBSD: 26 ans d'experience feront toujours la difference |
You could post your weather routing configuration.xml Boat.xml etc to be sure. Did it really not work when land detection is off? Is the polar file you are using in a writeable location? It needs to On 6/16/16, mbouyer notifications@github.com wrote:
|
On Thu, Jun 16, 2016 at 06:16:27AM -0700, seandepagnier wrote:
Yes, this is the issue. I'm using a polar installed with the I guess there's room for an error dialog here :) Also, I used to see isochrones on the map while the route was being computed Manuel Bouyer bouyer@antioche.eu.org NetBSD: 26 ans d'experience feront toujours la difference |
On Thu, Jun 16, 2016 at 03:48:28PM +0200, Manuel Bouyer wrote:
BTW you'll find WeatherRoutingConfiguration.xml and Boat.xml in Manuel Bouyer bouyer@antioche.eu.org NetBSD: 26 ans d'experience feront toujours la difference |
l.contours so perhaps this is the issue.
Sorry about that, and thanks for testing and reporting it... I will
Under View->Settings make sure the thickness is greater than 0. The |
On Thu, Jun 16, 2016 at 07:01:01AM -0700, seandepagnier wrote:
Yes, that would the best choise I guess
it is. I also tested different thickness values.
This doesn't change anything. Note that I see the wind barbs corresponding Manuel Bouyer bouyer@antioche.eu.org NetBSD: 26 ans d'experience feront toujours la difference |
Have tried the mbouyer files: TLsucMnOnoSYmtRzKDl0e75I4HAjqDApvbb.grb.txt Again, Failure. This is futile. |
Sean, Am I building this plugin correctly? When compiling with MSVC++ Build without error, 6 warnings in attached txt.
|
In windows, I would think that C:\ProgramData\opencpn\plugins\weather_routing\data\polars should be writable by the program!! I since isochrones are set att 1 hour, I changed max diverted course to 180 Immediately "Grib version not supported" hit OK Set the time period to 20 minutes. there is no messate about grib file. |
Copied all C:\Program Files (x86)\OpenCPN\plugins\weather_routing_pi\data\polars --Does not seem to make a difference. Stilll sits there "Computing..." |
Have git cloned Sean's wx_route branch:master and built. The plugin should:
|
I hit "ok" , "Computing..." continues. Screen goes black. Opencpn stops responding. Have to close abnormally or it just sits there. Ocpn log file attached. |
Don't seem to be getting anywhere on this, so I quit now. |
The GRIB INCOMPATIBLE MESSAGES ARE NOT DETAILED ENOUGH. Second Thought: After the message, Perhaps the Plugin should state what it is compatible with??? Note: I wasted several days of intermittent work, on this problem. I think it is totally worthwhile being explicit. Also the message does not seem to be very persistant. It comes up at the beginning and if you say OK nothing really happens. YOu can reload the grib or continue I think.. |
Also, I am not understanding the point or reason for making this weather_routing INCOMPATIBLE with OpenCPN 4.2 ? What's new? We changed grib files all ready! |
Sean, you can close this when you wish, other than noting the message just above. |
I didn't make it incompatible on purpose... I can try to work on the messages. On 6/16/16, Rick Gleason notifications@github.com wrote:
|
tl;dr: thanks for all your work, and please tell us how we can help. Hi Sean, first of all, I'm sure I speak for everyone here when thanking you from the bottom of my heart for all the wonderful work you do for this community. Please don't take our criticism and complaints as anything but an attempt to help. I think part of the problem is that this weather routing is very complex, and many of us do not understand the dependencies between all the parameters and options. This I think can be addressed in two ways: better logging / error messages, and/or smarter selection of defaults. One concrete example for the latter: I ended up always using the most extreme values for them in the hope that this will make things "better":
I'm not even sure that these values make things better or not. My guess is they are used for clipping the search tree and given I'm running on a powerful laptop (and all my route calculations finish within 2 minutes) I went overboard (I obviously do not plan to sail in 200 knots of wind!). But perhaps this is all wrong and I should instead use other values? But which ones? So what would be really helpful would be for the plugin to advise (e.g. "you are trying to plan a route of 5000 nm, so using 10 minute time steps will take forever!"). Of course even better would be if it would automatically pick the "right" values based on the scenario. Or even dynamically (e.g. "5 minutes" close to obstacles and "5 hours" in the middle of the ocean within steady trade winds), but that seems much more complicated. So better logging might be the easier answer. Or perhaps a "guided tour" on how you debug such problems. What do you look for in config variables, where do you set break points, what data is a "red flag" (e.g.: "whenever configuration.polar_failed is true, you are in big trouble"). I would be willing to contribute to a FAQ document for this, but right now I'm more likely to spread misinformation than providing real help. |
Sorry Sean,
Yes, understood. No problem I think. Maybe we just call it compatible with v4.4. I echo norbert's thanks wholeheartedly. PS have used new version a number of times now and it seems to be pretty reliable. |
PS: Sean, if you could get a few more messages to help us all, it would be great.
Sort of like that. |
I already know this.
Sometimes I get confused as well. I think the biggest issue is when the calculation "fails" but the exact reason isn't clear to the user.
This isn't wrong, and as you say will just prevent the tree from getting clipped by these parameters.
How can it know the correct time step? If I really want a 5 minute timestep for a route that takes 5 hours, it is going to be annoying to have the program smarter than it should be try to "help" me. Maybe an "auto" button for timestep, or the timestep starts out at 0 by default (which is invalid) and gets set to a reasonable value once both start and end positions are known. If the start or end changes... it probably shouldn't change the time step though.
Yes, well it is difficult to make error messages unless they are somewhat cryptic. A route could fail when the north half is bounded by lack of grib data, and the south half cannot be explored because none of the polars define a boat speed for that amount of wind. As you can see, the route fails when there is no where to explore, and each point in the route can get stopped for various reasons, so there is no clear error message to write other than "Failed" Now maybe you want me to count all the last positions and say something like "300 points failed to propagate due to edge of grib area, 200 failed because out of grib time, 150 failed from constraints (too much wind or...) and 50 because no suitable polar etc.." Also... I could maybe list the reason for propagation failure for each specific position in the cursor position dialog. Even then with such a message there are many details missing. So maybe we can step back and try to rethink this? As for guided tour, I think when people post videos on youtube it can work for this? |
Rick,
How exactly do I trigger this case.
Done
Ok...
Maybe you are confused here
How does the program determine the polar is screwed up? It could do this when you initially add the polar if I knew how.
Again, how does the program know this? Are there particular values that are incompatible with each other that I am not aware of?
you can just remove all the polars and choose only one, then delete all configurations and points. |
Sean, Thanks. Very interesting points I did not know. Ok. to "Reset to original configuration"
I'm going to close this now. OK? |
Correct cloudsmith upload script template
Just built Pavel's repos with #38
and tried routing with a Saildocs + Current. The files had different start and end times, but I set the grib time to the first frame when both gribs had data, and set the Route start time to that, and it fails still.
Then just tried a single regular non-grib2 GFS saildocs file and O fails.
The plugin seems to be broken, won't route a simple routing with a GFS Saildocs file.
Tried a number of times and different ways.
Sorry.
Win10
v4.2.1706
Weather_routing_pi from Pavel's repos - (just saw) Sean has merged this 21 hours ago.
will try that.
The text was updated successfully, but these errors were encountered: