Plotting Cylindrical Map Data Over A 3D Sphere in Python - Stack Overflow
Plotting Cylindrical Map Data Over A 3D Sphere in Python - Stack Overflow
log in
tour
help
Ad Options
Ads by Lyrics
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no
registration required.
3d
matplotlib
plot
add a comment
2 Answers
the basemap toolkit is ideal for this task.
The Problem seems to be that you don't really have the data, i.e. something like lat,lon,value for each
pixel. The problem is also that for a given image, you normally don't know the projection which was used
to create the image, therefore you cannot do the back-transformation to get the original data.
If you just like to plot a image of the earth, use the bluemarble() function from the basemap toolkit:
http://wiki.scipy.org/Cookbook/Matplotlib/Maps
answered Jun 28 '13 at 13:49
Raphael Roth
624 3 12
I am not interested on Earth precisely, but your answer gave me great insight: the bluemarble function calls
warpimage : github.com/matplotlib/basemap/blob/master/lib/mpl_toolkits/ which might be exactly what I
want. I'll try this later, thanks. Juanlu001 Jun 28 '13 at 14:25
add a comment
Thanks to Raphael Roth answer I finally found what I was looking for: the function warpimage.
Here is a very minimal example. Using this cylindrical map of Venus, and based on the simple example of
the cookbook:
http://stackoverflow.com/questions/17365364/plotting-cylindrical-map-data-over-a-3d-sphere-in-python
1/3
11/18/2014
WebSpades Ads
Ads by Lyrics
Trust Rating
95%
stackoverflow.com
cool, good to know that this is possible Raphael Roth Jun 29 '13 at 5:13
add a comment
Not the answer you're looking for? Browse other questions tagged python 3d
matplotlib
http://stackoverflow.com/questions/17365364/plotting-cylindrical-map-data-over-a-3d-sphere-in-python
2/3
11/18/2014
Ads by Lyrics
http://stackoverflow.com/questions/17365364/plotting-cylindrical-map-data-over-a-3d-sphere-in-python
Ad Options
3/3