Commit Graph
988 Commits
Author SHA1 Message Date
Géraud 0fbc7ef3f7 ENH: write GeoDataFrame with mixed geometry types (#870) 2019-04-17 18:01:50 +02:00
Joris Van den Bossche ab5945bee6 BUG: unary/binary geo ops with all-empty result raise error (#914) 2019-04-17 15:17:13 +02:00
Joris Van den Bossche 59bbca801b TST/CI: pin a few builds to older fiona version (#973) 2019-04-17 12:47:32 +02:00
Yohann Rebattu d39b6429c9 PERF: Optimize pyproj >= 2.1 transformations (#962) 2019-04-16 21:11:19 +02:00
Joris Van den Bossche 5a222cc3c4 TST/CI: update CRS tests + ensure compatibility with proj.4 6 / pyproj 2 (#971) 2019-04-16 14:19:28 +02:00
Joris Van den Bossche 617b141bf1 TST: skip plotting tests if matplotlib is not installed (#970) 2019-04-15 14:40:24 +02:00
byrman 8a61854a15 DOC: buffer resolution is an int, not a float (#968) 2019-04-12 15:14:53 +02:00
Brian Lewis 08ad2bfea1 Fix broken links to Shapely and Fiona docs (#954) 2019-03-31 20:55:33 -07:00
Joris Van den Bossche 619c99c221 CI: update travis builds (#949)
- remove py27 dev build (pandas master no longer supports python 2.7) and replace with pandas 0.23 build
- py37 dev build: move installing pandas and matplotlib master to separate steps in travis yml file (otherwise the conda create step takes too long)
- remove conda-forge/label/dev label for fiona (was still installing the rc instead of actual released version)
2019-03-25 16:23:28 +01:00
Andy Garfield f5c9008dfe Minor typo fix (#948) 2019-03-21 18:52:09 +01:00
Filipe 68c337df83 CI: update miniconda version (#935) 2019-03-06 14:51:53 +01:00
Joris Van den Bossche 3ab046544b DOC/BLD: readthedocs version 2 config file (#934) 2019-03-06 11:36:05 +01:00
Joris Van den Bossche 6dd50b80dc DOC: fix random state in geoplot voronoi example to prevent random errors (#933)
See ResidentMario/geoplot#69: depending on how the data are subsampled, we stumble into a potential bug in geoplot. So fixing the random state with a working one to prevent this.
2019-03-06 09:57:48 +01:00
TimoRoth 3c66dece17 COMPAT: use .item() instead of deprecated np.asscalar() (#930) 2019-03-06 09:20:08 +01:00
Joris Van den Bossche 44b52a17f3 DOC: pin versions in readthedocs environment.yml file (#932) 2019-03-05 23:50:51 +01:00
Joris Van den Bossche b01e62adc0 Ensure GeoSeries.isna is always a Series and not GeoSeries (#931) 2019-03-05 22:52:44 +01:00
Joris Van den Bossche f2713fc31a DOC: changelog for 0.4.1 bugfix release (#929) 2019-03-05 22:41:24 +01:00
Joris Van den Bossche 6e49375606 DOC: rework installation docs (#926) 2019-03-05 21:53:06 +01:00
Philipp Kats ca3216ece5 DOC: update fiona / shapely links (#919) 2019-02-14 20:24:18 +00:00
Kris Vanhoof b37dbe0893 Read in a fiona.Env() block to make sure GDAL_DATA is set (#916) 2019-02-11 16:34:08 +00:00
Justin Shenk 6e6843e195 Fix readme doc formatting (#917) 2019-02-11 13:18:15 +00:00
Martin Fleischmann 39e724b475 ENH Provide API to convert x, y(, z) coordinates to geometry (#896) 2019-02-07 15:42:14 +00:00
James McBride 27d3361699 TST: Make port settable or gettable from env (#906)
* TST: Make port settable or gettable from env

As raised in #822, may be useful to have the postgis port settings more
generic.

* Add other postgres env settings too

* Add more documentation on postgis test setup
2019-02-03 21:07:24 -08:00
James McBride cc1ac11e8d Set geocodefarm as default geocoding service (#907)
Set nominatim as default geocoding service
2019-02-03 14:53:08 -08:00
Martin Fleischmann 0d2d5206ee added examples (#909) 2019-01-31 22:14:47 -08:00
Raphael Delhome c6b32ce375 Consider a new plotting artist for improving colormap legends (#894)
* Consider a new plotting artist for improving colormap legends

* test: add a unit test for verifying legend height

* plotting: manage 'cax' argument without 'ax' one

* test: add a missing 'abs(.)' function to cax height test

* doc: complete 'mapping.rst' with details about the choropleth legends

* Update mapping.rst

Make explanation of colorbar example more concise
2019-01-30 20:49:12 -08:00
Joris Van den Bossche 80b059a53d TST: reorganize IO tests (#905) 2019-01-26 21:54:56 +01:00
Joris Van den Bossche 2d6b78b28b TST: fix to_csv test on Windows (#904)
Pandas 0.24 changed default lineterminator
to os.linesep (so OS dependent now).
2019-01-26 15:44:09 +01:00
Joris Van den Bossche 02c6cf6d2b CI: fix the conda-forge env with pd 0.20 (remove pin of old matplotlib) (#903)
Travis CI tests were failing recently for one specific build, see https://github.com/conda-forge/gdal-feedstock/issues/261

Fixed by removing the pin of matplotlib to 1.5.3 (but added `gdal=2.3` to keep at older gdal version). 

Also added `nomkl` to have a built with numpy/openblas from conda-forge (not that it should matter though).
2019-01-26 14:08:18 +01:00
James McBride ddaa26fdba Add very basic benchmarks for file reading/writing (#890)
* Add very basic benchmarks for file reading/writing

Just created a moderate sized series and frame and tested reading and
writing.

* Add benchmarks for other file extensions
2019-01-06 21:27:57 -08:00
James McBride 2ac0f97385 DOC: Add geoplot example back to doc (#892)
Docs were failing because expected failure was unexpectedly not failing.
:)
Also minor changes to postgis doc in order to quiet warning.
2019-01-05 14:06:45 -08:00
Martin Fleischmann 10e1093f27 fixed expected values to match new dataset (#891) 2019-01-05 13:37:06 -08:00
Joris Van den Bossche c2c5f9dd25 DOC: temp allow failure in geoplot example gallary (#889) 2019-01-02 09:48:37 +01:00
James McBride 323cccc532 Use geocodefarm rather than google for example (#888)
The request to google is frequently (always?) failing in the past few
months, so use geocodefarm instead for the example of how to use
geocoding in geopandas.
2019-01-01 21:54:36 -08:00
Jesse Pisel e7f320baae updated the demo dataset (#808)
* updated the demo dataset

new shapefiles from http://www.naturalearthdata.com/downloads/110m-cultural-vectors/110m-admin-0-countries/

* script to create example dataset

Reads the earth data from naturalearth.com as a geojson and selects the 6 columns used to create the example datasets.

* changed shapefile source

added the .zip file from naturalearth.com with version 4.1.0 shapefiles. Also added a line that changes column names to lowercase to match the example dataset

* removed .zip shapefile

I wasn't sure if I should include the .zip or not. It's removed now. Thank you for clarifying.

* added module docstring

* Make small revisions to demo dataset creation file
2019-01-01 21:16:26 -08:00
YuichiNotoya c5fbb379a4 Make interiors method correspond to non-polygons (#859)
* Make interiors method correspond to non-polygons

* Add warnings to non-polygon and convert to list

* Re-worded interiors warning for non-Polygons
2018-12-31 14:27:36 -08:00
Martin Fleischmann c8abcb4bef Access to all mapclassify schemes including keywords (#235, #357) (#876)
* access to all mapclassify schemes including keywords (#235, #357)

* test for classificaition_kwds

* scheme docstring to get rid of selection of schemes

* Explicit list of possible schemes in docstring

* New classification schemes in docs (and changed PySAL to mapclassify)

* import all mapclassify clasifiers instead passing them explicitly

* inspect compatible with python 2

* fix getargspec for python 2.7

* minor update of docs
2018-12-18 22:05:48 -08:00
Joshua Wilson cd8bc88848 ENH: get explicit CRS from EPSG code (#678)
* added method for getting long-definition of epsg codes

* more testing for explicit_crs_from_epsg

* more testing for explicit_crs_from_epsg

* added new function `epsg_from_crs`
2018-12-17 22:31:51 -08:00
Martin Fleischmann 41ea283917 BUG: Ignore NaN in setting mn and mx (#877) (#878)
* ignore nan in setting mn and mx

* test if vmin vmax set correctly for array with NaN

* test compatible with older versions

* reference to issue and shorter assert in test
2018-12-12 14:52:22 -08:00
Émile Nadeau 14dee6a01c ENH: parse date for read_postgis (#860)
* ENH: parse date for read_postgis

* ENH: parse date for from_postgis
2018-12-11 21:38:07 -08:00
Joris Van den Bossche fab445abd1 ENH: support writing bool dtype with fiona>=1.8 (#855) 2018-12-09 10:29:07 +01:00
YuichiNotoya 8aae84e2c7 ENH: Implementation of relate method (#853) 2018-12-09 09:28:28 +01:00
YuichiNotoyaandJoris Van den Bossche 4f933d38f1 PERF: Improve iterfeatures performance (#864)
Co-authored-by: Joris Van den Bossche <jorisvandenbossche@gmail.com>
2018-12-09 09:13:20 +01:00
Brett Naul 6e9b82b855 Default to 'Unknown' geometry schema (#827)
* Default to `'Unknown'` geometry schema

* Add GeoJSON to_file test

* Add comment to test
2018-12-08 21:47:46 -08:00
Martin Fleischmann f4fa69eae0 Use mapclassify instead of PySAL due to change of PySAL structure. (#872) 2018-12-08 22:36:45 +01:00
Joris Van den Bossche bf7ba2f6a2 DOC: continue doc build on warnings/errors in examples (#873) 2018-12-08 21:15:13 +01:00
Dmitry Nikolaev 483f29ca88 DOC: fix param name for GeoDataFrame.set_geometry (#871) 2018-12-06 10:48:51 +01:00
lmmarsano 201ae9cd93 BUG: fix from_postgis to accept nullable geometry (#856)
* TST: test read_postgis with NULL geometry

Though GIS databases permit NULL values in the geometry field, read_postgis throws exceptions when it encounters them.
test_read_postgis_null_geom defines this test case with sqlite3 database, and support functions are revised to support it.
create_sqlite is revised to loosen data type restrictions and follow [recommendations from the python manual](https://docs.python.org/3/library/sqlite3.html)
- connection parameter instead of filename to allow for in-memory database
- 'with' statement for transaction management
- parameter substitution instead of string operations
validate_boro_df strips NULL values before checking geometry type.

* TST: replace sqlite test with spatialite test

The original SQLite test reflected unlikely usage for geospatial analysis.
In parity with PostGIS, the new test runs against SQLite with SpatiaLite enabled.
For coverage, test geometries read as text and binary.

* TST: add libspatialite as a test dependency

* TST: add conda-forge testing environment for Python 2.7

add this environment to continuous integration
conda-forge Python 2.7 enables loadable SQLite extensions with conda-forge/python-feedstock#227
adding this environment enables SpatiaLite tests

* BUG: fix read_postgis & GeoDataFrame to accept NULL geometry values

read_postgis failed to load nullable binary geometry data while GeoDataFrame raised exceptions on NULL in the geometry field.
This fixes both issues.
It moreover adds logic to detect python version & load geometries from
python 2 buffers as necessary.

* ENH DOC: drop hex_encoded parameter from read_postgis & from_postgis

drop hex_encoded, since sqlite3 represents binary & text as distinct Python data types
adjust names to clarify this distinction
adjust documentation to clarify geometry is expected in WKB representation (which was implicit)
add example SpatiaLite usage reflecting this expectation
2018-11-29 21:05:08 -08:00
Joris Van den Bossche 9e584ccdd6 Use fiona.Env() for new versions to avoid warning (#854) 2018-11-17 09:56:02 +01:00
Leah Wasser 1eba57a71b Contributing file updates python 2.7 instead of 2.6 + a few other syntax consistency edits (#851)
* Fixing minor misspelling in Contributing.md file

* Updating CONTRIBUTING file to reflect python 3.x

* Support for Python v 2.7 edits

* Consistent capitalization  of Python

* Adjust python support version
2018-11-07 20:51:02 -08:00