Skip to content
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

SF#394 demo cartography fails #137

Closed
zmughal opened this issue Aug 14, 2015 · 7 comments · Fixed by #138
Closed

SF#394 demo cartography fails #137

zmughal opened this issue Aug 14, 2015 · 7 comments · Fixed by #138

Comments

@zmughal
Copy link
Member

zmughal commented Aug 14, 2015

From https://sourceforge.net/p/pdl/bugs/394/

Testing the demos in the latest PDL-2.013 release, the cartography demo resulted in a crash.
Investigating, the problem is in the Demos/Cartography_demo.pm file where the map and
graticule are generated/loaded:

### Get the vector coastline map (and a lon/lat grid), and load the Earth
### RGB daytime image -- both of these are built-in to the module. The
### coastline map is a set of (X,Y,Pen) vectors.
$coast = earth_coast() -> glue( 1, graticule(15,1) );
print "Coastline data are a collection of vectors:  ",
   join("x",$coast->dims),"\n";

Yielding the error:

  OOPS!!! Something went wrong, please make a bug report!: PDL: PDL::Primitive::append(a,b,c):
  Parameter 'b':  Mismatched implicit thread dimension 0: size 3 vs. 2
  There are 3 PDLs in the expression; 1 thread dim....

The problem arises because graticule() returns 2 pdls in list context but
one of shape [3,N] for scalar context. Scalar context must be forced for
the thread dimensions to match:

 $coast = earth_coast() -> glue( 1, scalar(graticule(15,1)) );
@mohawk2
Copy link
Member

mohawk2 commented Aug 16, 2015

I just posted this on that issue:

"Milestone: critical"? Does this mean no other progress can happen with PDL until this issue is resolved?

There needs to be tests of the Demos just like of the substantive code, but more than that; there needs to be the great split so that the cartography stuff is in its own distro and can be fixed and released in its own time.

@devel-chm
Copy link
Member

I added a default normal category for milestone to the sf.net bugs tracker. Thanks for the reminder.

@mohawk2
Copy link
Member

mohawk2 commented Aug 16, 2015

@devel-chm Nice! Look forward to your thoughts on PDL::IO::GD.

@zmughal
Copy link
Member Author

zmughal commented Aug 17, 2015

@d-lamb, I saw your changes in the sf#394 branch. You can open a pull request on GitHub and from there we can see all the tests running on Travis-CI (Linux) and Appveyor CI (Windows)!

I know that it is a small change, but I'd like to get everyone on board with this workflow. It makes team-based development easier.

@zmughal
Copy link
Member Author

zmughal commented Aug 17, 2015

Also, you should be in the PDLPorters GitHub org. I'll invite you if you'd like.

@d-lamb
Copy link
Member

d-lamb commented Aug 17, 2015

On Aug 17, 2015, at 11:34 AM, Zaki Mughal [sivoais] notifications@github.com wrote:

Also, you should be in the PDLPorters GitHub org. I'll invite you if you'd like.


Reply to this email directly or view it on GitHub #137 (comment).

Yes, please. Then I'll initiate the pull request. Let me know if I do anything sub-optimal.

@zmughal
Copy link
Member Author

zmughal commented Aug 17, 2015

Invite sent!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants