[TriPython] Setting a 10m buffer on a point in Geopandas

Ryan Cooper ryancooper729 at gmail.com
Thu Jun 7 11:37:13 EDT 2018


Greg-

As I was looking closer at your notebook and the error message you sent it
occurred to me that perhaps the original CRS, EPSG:4326, was not set on the
geometry series of your GeoDataFrame. As such there would be no way to
transform your data from EPSG:4326 to EPSG:3395. See notebook here for a
possible solution to your issue.
<https://gist.github.com/maptastik/efbb023e70b2d02c60a7c610805cb672>

On Thu, Jun 7, 2018 at 10:49 AM, Greg Frazier <gnfrazier at gmail.com> wrote:

>    Thanks Ryan,
>    That threw an error:
>
>  ValueError: Cannot transform naive geometries.  Please set a crs on the
> object first.
>
>    But it got me thinking. I added the to_crs line under the line that
>    assigned the CRS and it seemed to help the issue with plotting. However
> it
>    made no difference in the size of the polygon objects, they continue to
>    increment by degree of lat/long.
>    I may go through the tricky exercise of setting the buffer size by
> degrees
>    based on the latitude of the point. Tricky mostly because it has been 20
>    years since I had a calculus class.
>
> _______________________________________________
> TriZPUG mailing list
> TriZPUG at python.org
> https://mail.python.org/mailman/listinfo/trizpug
> http://tripython.org is the Triangle Python Users Group
>
>


-- 
Ryan Cooper
Email: ryancooper729 at gmail.com
Web: ryan-m-cooper.com
Twitter: @maptastik <https://twitter.com/maptastik>
GitHub: maptastik <http://github.com/maptastik>
-------------- next part --------------
   Greg-
   As I was looking closer at your notebook and the error message you sent it
   occurred to me that perhaps the original CRS, EPSG:4326, was not set on
   the geometry series of your GeoDataFrame. As such there would be no way to
   transform your data from EPSG:4326 to EPSG:3395.**[1]See notebook here for
   a possible solution to your issue.
   On Thu, Jun 7, 2018 at 10:49 AM, Greg Frazier <[2]gnfrazier at gmail.com>
   wrote:

     ** **Thanks Ryan,
     ** **That threw an error:

     **ValueError: Cannot transform naive geometries.** Please set a crs on
     the object first.

     ** **But it got me thinking. I added the to_crs line under the line that
     ** **assigned the CRS and it seemed to help the issue with plotting.
     However it
     ** **made no difference in the size of the polygon objects, they
     continue to
     ** **increment by degree of lat/long.
     ** **I may go through the tricky exercise of setting the buffer size by
     degrees
     ** **based on the latitude of the point. Tricky mostly because it has
     been 20
     ** **years since I had a calculus class.

     _______________________________________________
     TriZPUG mailing list
     [3]TriZPUG at python.org
     [4]https://mail.python.org/mailman/listinfo/trizpug
     [5]http://tripython.org is the Triangle Python Users Group

   --
   Ryan Cooper
   Email:**[6]ryancooper729 at gmail.com
   Web:**[7]ryan-m-cooper.com
   Twitter:**[8]@maptastik
   GitHub:**[9]maptastik

References

   Visible links
   1. https://gist.github.com/maptastik/efbb023e70b2d02c60a7c610805cb672
   2. mailto:gnfrazier at gmail.com
   3. mailto:TriZPUG at python.org
   4. https://mail.python.org/mailman/listinfo/trizpug
   5. http://tripython.org/
   6. mailto:ryancooper729 at gmail.com
   7. http://ryan-m-cooper.com/
   8. https://twitter.com/maptastik
   9. http://github.com/maptastik


More information about the TriZPUG mailing list