Climada

Latest version: v4.3.3

Safety actively analyzes 623518 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

4.1.1

Release date: 2024-02-21

Fixed

- Fix `util.coordinates.latlon_bounds` for cases where the specified buffer is very large so that the bounds cover more than the full longitudinal range `[-180, 180]` [839](https://github.com/CLIMADA-project/climada_python/pull/839)
- Fix `climada.hazard.trop_cyclone` for TC tracks crossing the antimeridian [839](https://github.com/CLIMADA-project/climada_python/pull/839)

4.1.0

Release date: 2024-02-14

Dependency Changes

Added:

- `pyproj` >=3.5
- `numexpr` >=2.9

Updated:

- `contextily` >=1.3 → >=1.5
- `dask` >=2023 → >=2024
- `numba` >=0.57 → >=0.59
- `pandas` >=2.1 &rarr; >=2.1,<2.2
- `pint` >=0.22 &rarr; >=0.23
- `scikit-learn` >=1.3 &rarr; >=1.4
- `scipy` >=1.11 &rarr; >=1.12
- `sparse` >=0.14 &rarr; >=0.15
- `xarray` >=2023.8 &rarr; >=2024.1
- `overpy` =0.6 &rarr; =0.7
- `peewee` =3.16.3 &rarr; =3.17.1

Removed:

- `proj` (in favor of `pyproj`)

Added

- Convenience method `api_client.Client.get_dataset_file`, combining `get_dataset_info` and `download_dataset`, returning a single file objet. [821](https://github.com/CLIMADA-project/climada_python/pull/821)
- Read and Write methods to and from csv files for the `DiscRates` class. [818](ttps://github.com/CLIMADA-project/climada_python/pull/818)
- Add `CalcDeltaClimate` to unsequa module to allow uncertainty and sensitivity analysis of impact change calculations [844](https://github.com/CLIMADA-project/climada_python/pull/844)
- Add function `safe_divide` in util which handles division by zero and NaN values in the numerator or denominator [844](https://github.com/CLIMADA-project/climada_python/pull/844)
- Add reset_frequency option for the impact.select() function. [847](https://github.com/CLIMADA-project/climada_python/pull/847)

Changed

- Update Developer and Installation Guides for easier accessibility by new developers. [808](https://github.com/CLIMADA-project/climada_python/pull/808)
- Add `shapes` argument to `geo_im_from_array` to allow flexible turning on/off of plotting coastline in `plot_intensity`. [805](https://github.com/CLIMADA-project/climada_python/pull/805)
- Update `CONTRIBUTING.md` to better explain types of contributions to this repository [797](https://github.com/CLIMADA-project/climada_python/pull/797)
- The default tile layer in Exposures maps is not Stamen Terrain anymore, but [CartoDB Positron](https://github.com/CartoDB/basemap-styles). Affected methods are `climada.engine.Impact.plot_basemap_eai_exposure`,`climada.engine.Impact.plot_basemap_impact_exposure` and `climada.entity.Exposures.plot_basemap`. [#798](https://github.com/CLIMADA-project/climada_python/pull/798)
- Recommend using Mamba instead of Conda for installing CLIMADA [809](https://github.com/CLIMADA-project/climada_python/pull/809)
- `Hazard.from_xarray_raster` now allows arbitrary values as 'event' coordinates [837](https://github.com/CLIMADA-project/climada_python/pull/837)
- `climada.test.get_test_file` now compares the version of the requested test dataset with the version of climada itself and selects the most appropriate dataset. In this way a test file can be updated without the need of changing the code of the unittest. [822](https://github.com/CLIMADA-project/climada_python/pull/822)
- Explicitly require `pyproj` instead of `proj` (the latter is now implicitly required) [845](https://github.com/CLIMADA-project/climada_python/pull/845)

Fixed

- `Hazard.from_xarray_raster` now stores strings as default values for `Hazard.event_name` [795](https://github.com/CLIMADA-project/climada_python/pull/795)
- Fix the dist_approx util function when used with method="geosphere" and log=True and points that are very close. [792](https://github.com/CLIMADA-project/climada_python/pull/792)
- `climada.util.yearsets.sample_from_poisson`: fix a bug ([819](https://github.com/CLIMADA-project/climada_python/issues/819)) and inconsistency that occurs when lambda events per year (`lam`) are set to 1. [[#823](https://github.com/CLIMADA-project/climada_python/pull/823)]
- In the TropCyclone class in the Holland model 2008 and 2010 implementation, a doublecounting of translational velocity is removed [833](https://github.com/CLIMADA-project/climada_python/pull/833)
- `climada.util.test.test_finance` and `climada.test.test_engine` updated to recent input data from worldbank [841](https://github.com/CLIMADA-project/climada_python/pull/841)
- Set `nodefaults` in Conda environment specs because `defaults` are not compatible with conda-forge [845](https://github.com/CLIMADA-project/climada_python/pull/845)
- Avoid redundant calls to `np.unique` in `Impact.impact_at_reg` [848](https://github.com/CLIMADA-project/climada_python/pull/848)

4.0.2

Release date: 2023-09-27

Dependency Changes

- `pandas` >=1.5,<2.0 &rarr; >=1.5 (compatibility with pandas 2.x)

Changed

- improved integration tests for notebooks and external data apis

Fixed

- implicit casting from `DataArray` to `int` in reading mehtods made explicit [95](https://github.com/CLIMADA-project/climada_petals/pull/95/files)

4.0.1

Release date: 2023-09-27

Dependency Changes

Added:

- `matplotlib-base` None &rarr; >=3.8

Changed:

- `geopandas` >=0.13 &rarr; >=0.14
- `pandas` >=1.5,<2.0 &rarr; >=2.1

Removed:

- `matplotlib` >=3.7

Changed

- Rearranged file-system structure: `data` directory moved into `climada` package directory. [781](https://github.com/CLIMADA-project/climada_python/pull/781)

Fixed

- `climada.util.coordinates.get_country_code` bug, occurring with non-standard longitudinal coordinates around the anti-meridian. [770](https://github.com/CLIMADA-project/climada_python/issues/770)

4.0.0

Release date: 2023-09-01

Dependency Updates

Added:

- `pytest` [726](https://github.com/CLIMADA-project/climada_python/pull/726)
- `pytest-cov` [726](https://github.com/CLIMADA-project/climada_python/pull/726)
- `pytest-subtests` [726](https://github.com/CLIMADA-project/climada_python/pull/726)
- `unittest-xml-reporting`

Changed:

- `cartopy` >=0.20.0,<0.20.3 &rarr; >=0.21
- `cfgrib` >=0.9.7,<0.9.10 &rarr; =0.9.9
- `contextily` >=1.0 &rarr; >=1.3
- `dask` >=2.25 &rarr; >=2023
- `eccodes` [auto] &rarr; =2.27
- `gdal` !=3.4.1 &rarr; >=3.6
- `geopandas` >=0.8 &rarr; >=0.13
- `h5py` >=2.10 &rarr; >=3.8
- `haversine` >=2.3 &rarr; >=2.8
- `matplotlib` >=3.2,< 3.6 &rarr; >=3.7
- `netcdf4` >=1.5 &rarr; >=1.6
- `numba` >=0.51,!=0.55.0 &rarr; >=0.57
- `openpyxl` >=3.0 &rarr; >=3.1
- `pandas-datareader` >=0.9 &rarr; >=0.10
- `pathos` >=0.2 &rarr; >=0.3
- `pint` >=0.15 &rarr; >=0.22
- `proj` !=9.0.0 &rarr; >=9.1
- `pycountry` >=20.7 &rarr; >=22.3
- `pytables` >=3.6 &rarr; >=3.7
- `rasterio` >=1.2.7,<1.3 &rarr; >=1.3
- `requests` >=2.24 &rarr; >=2.31
- `salib` >=1.3.0 &rarr; >=1.4
- `scikit-learn` >=1.0 &rarr; >=1.2
- `scipy` >=1.6 &rarr; >=1.10
- `sparse` >=0.13 &rarr; >=0.14
- `statsmodels` >=0.11 &rarr; >=0.14
- `tabulate` >=0.8 &rarr; >=0.9
- `tqdm` >=4.48 &rarr; >=4.65
- `xarray` >=0.13 &rarr; >=2023.5
- `xlrd` >=1.2 &rarr; >=2.0
- `xlsxwriter` >=1.3 &rarr; >=3.1

Removed:

- `nbsphinx` [712](https://github.com/CLIMADA-project/climada_python/pull/712)
- `pandoc` [712](https://github.com/CLIMADA-project/climada_python/pull/712)
- `xmlrunner`

Added

- `Impact.impact_at_reg` method for aggregating impacts per country or custom region [642](https://github.com/CLIMADA-project/climada_python/pull/642)
- `Impact.match_centroids` convenience method for matching (hazard) centroids to impact objects [602](https://github.com/CLIMADA-project/climada_python/pull/602)
- `climada.util.coordinates.match_centroids` method for matching (hazard) centroids to GeoDataFrames [602](https://github.com/CLIMADA-project/climada_python/pull/602)
- 'Extra' requirements `doc`, `test`, and `dev` for Python package [712](https://github.com/CLIMADA-project/climada_python/pull/712)
- Added method `Exposures.centroids_total_value` to replace the functionality of `Exposures.affected_total_value`. This method is temporary and deprecated. [702](https://github.com/CLIMADA-project/climada_python/pull/702)
- New method `climada.util.api_client.Client.purge_cache`: utility function to remove outdated files from the local file system to free disk space.
([737](https://github.com/CLIMADA-project/climada_python/pull/737))
- New attribute `climada.hazard.Hazard.haz_type`: used for assigning impacts to hazards. In previous versions this information was stored in the now removed `climada.hazard.tag.Tag` class. [736](https://github.com/CLIMADA-project/climada_python/pull/736)
- New attribute `climada.entity.exposures.Exposures.description`: used for setting the default title in plots from plotting mathods `plot_hexbin` and `plot_scatter`. In previous versions this information was stored in the deprecated `climada.entity.tag.Tag` class. [756](https://github.com/CLIMADA-project/climada_python/pull/756)
- Added advanced examples in unsequa tutorial for coupled input variables and for handling efficiently the loading of multiple large files [766](https://github.com/CLIMADA-project/climada_python/pull/766)

Changed

- Improved error messages from `climada.CONFIG` in case of missing configuration values [670](https://github.com/CLIMADA-project/climada_python/pull/670)
- Refactored `Exposure.assign_centroids` using a new util function `u_coord.match_centroids` [602](https://github.com/CLIMADA-project/climada_python/pull/602)
- Renamed `climada.util.coordinate.assign_grid_points` to `match_grid_points` and `climada.util.coordinates.assign_coordinates` to `match_coordinates`
[602](https://github.com/CLIMADA-project/climada_python/pull/602)
- Modified the method to disaggregate lines in the `lines_polys_handler` utility module in order to better conserve the total length of all lines on average [679](https://github.com/CLIMADA-project/climada_python/pull/679).
- Added test for non-default impact function id in the `lines_polys_handler` [676](https://github.com/CLIMADA-project/climada_python/pull/676)
- The sigmoid and step impact functions now require the user to define the hazard type. [675](https://github.com/CLIMADA-project/climada_python/pull/675)
- Improved error messages produced by `ImpactCalc.impact()` in case hazard type is not found in exposures/impf_set [691](https://github.com/CLIMADA-project/climada_python/pull/691)
- Tests with long runtime were moved to integration tests in `climada/test` [709](https://github.com/CLIMADA-project/climada_python/pull/709)
- Use `myst-nb` for parsing Jupyter Notebooks for the documentation instead of `nbsphinx` [712](https://github.com/CLIMADA-project/climada_python/pull/712)
- Installation guide now recommends installing CLIMADA directly via `conda install` [714](https://github.com/CLIMADA-project/climada_python/pull/714)
- `Exposures.affected_total_value` now takes a hazard intensity threshold as argument. Affected values are only those for which at least one event exceeds the threshold. (previously, all exposures points with an assigned centroid were considered affected). By default the centroids are reassigned. [702](https://github.com/CLIMADA-project/climada_python/pull/702) [#730](https://github.com/CLIMADA-project/climada_python/pull/730)
- Add option to pass region ID to `LitPop.from_shape` [720](https://github.com/CLIMADA-project/climada_python/pull/720)
- Slightly improved performance on `LitPop`-internal computations [720](https://github.com/CLIMADA-project/climada_python/pull/720)
- Use `pytest` for executing tests [726](https://github.com/CLIMADA-project/climada_python/pull/726)
- Users can opt-out of the climada specific logging definitions and freely configure logging to their will, by setting the config value `logging.managed` to `false`. [724](https://github.com/CLIMADA-project/climada_python/pull/724)
- Add option to read additional variables from IBTrACS when using `TCTracks.from_ibtracs_netcdf` [728](https://github.com/CLIMADA-project/climada_python/pull/728)
- New file format for `TCTracks` I/O with better performance. This change is not backwards compatible: If you stored `TCTracks` objects with `TCTracks.write_hdf5`, reload the original data and store them again. [735](https://github.com/CLIMADA-project/climada_python/pull/735)
- Add option to load only a subset when reading TC tracks using `TCTracks.from_simulations_emanuel`. [741](https://github.com/CLIMADA-project/climada_python/pull/741)
- Set `save_mat` to `False` in the `unsequa` module [746](https://github.com/CLIMADA-project/climada_python/pull/746)
- `list_dataset_infos` from `climada.util.api_client.Client`: the `properties` argument, a `dict`, can now have `None` as values. Before, only strings and lists of strings were allowed. Setting a particular property to `None` triggers a search for datasets where this property is not assigned. [752](https://github.com/CLIMADA-project/climada_python/pull/752)
- Reduce memory requirements of `TropCyclone.from_tracks` [749](https://github.com/CLIMADA-project/climada_python/pull/749)
- Support for different wind speed and pressure units in `TCTracks` when running `TropCyclone.from_tracks` [749](https://github.com/CLIMADA-project/climada_python/pull/749)
- The title of plots created by the `Exposures` methods `plot_hexbin` and `plot_scatter` can be set as a method argument. [756](https://github.com/CLIMADA-project/climada_python/pull/756)
- Changed the parallel package from Pathos to Multiproess in the unsequa module [763](https://github.com/CLIMADA-project/climada_python/pull/763)
- Updated installation instructions to use conda for core and petals [776](https://github.com/CLIMADA-project/climada_python/pull/776)

Fixed

- `util.lines_polys_handler` solve polygon disaggregation issue in metre-based projection [666](https://github.com/CLIMADA-project/climada_python/pull/666)
- Problem with `pyproj.CRS` as `Impact` attribute, [706](https://github.com/CLIMADA-project/climada_python/issues/706). Now CRS is always stored as `str` in WKT format.
- Correctly handle assertion errors in `Centroids.values_from_vector_files` and fix the associated test [768](https://github.com/CLIMADA-project/climada_python/pull/768/)
- Text in `Forecast` class plots can now be adjusted [769](https://github.com/CLIMADA-project/climada_python/issues/769)
- `Impact.impact_at_reg` now supports impact matrices where all entries are zero [773](https://github.com/CLIMADA-project/climada_python/pull/773)
- upgrade pathos 0.3.0 -> 0.3.1 issue [761](https://github.com/CLIMADA-project/climada_python/issues/761) (for unsequa module [#763](https://github.com/CLIMADA-project/climada_python/pull/763))
- Fix bugs with pandas 2.0 (iteritems -> items, append -> concat) (fix issue [700](https://github.com/CLIMADA-project/climada_python/issues/700) for unsequa module) [#763](https://github.com/CLIMADA-project/climada_python/pull/763))
- Remove matplotlib styles in unsequa module (fixes issue [758](https://github.com/CLIMADA-project/climada_python/issues/758)) [#763](https://github.com/CLIMADA-project/climada_python/pull/763)

Deprecated

- `Centroids.from_geodataframe` and `Centroids.from_pix_bounds` [721](https://github.com/CLIMADA-project/climada_python/pull/721)
- `Impact.tot_value`: Use `Exposures.affected_total_value` to compute the total value affected by a hazard intensity above a custom threshold [702](https://github.com/CLIMADA-project/climada_python/pull/702)
- `climada.entity.tag.Tag`. [779](https://github.com/CLIMADA-project/climada_python/pull/779). The class is not used anymore but had to be kept for reading Exposures HDF5 files that were created with previous versions of CLIMADA.

Removed

- `Centroids.set_raster_from_pix_bounds` [721](https://github.com/CLIMADA-project/climada_python/pull/721)
- `requirements/env_developer.yml` environment specs. Use 'extra' requirements when installing the Python package instead [712](https://github.com/CLIMADA-project/climada_python/pull/712)
- The `climada.entitity.tag.Tag` class, together with `Impact.tag`, `Exposures.tag`, `ImpactFuncSet.tag`, `MeasuresSet.tag`, `Hazard.tag` attributes.
This may break backwards-compatibility with respect to the files written and read by the `Impact` class.
[736](https://github.com/CLIMADA-project/climada_python/pull/736),
[743](https://github.com/CLIMADA-project/climada_python/pull/743),
[753](https://github.com/CLIMADA-project/climada_python/pull/753),
[754](https://github.com/CLIMADA-project/climada_python/pull/754),
[756](https://github.com/CLIMADA-project/climada_python/pull/756),
[767](https://github.com/CLIMADA-project/climada_python/pull/767),
[779](https://github.com/CLIMADA-project/climada_python/pull/779)
- `impact.tot_value` attribute removed from unsequa module [763](https://github.com/CLIMADA-project/climada_python/pull/763)

3.3.2

Release date: 2023-03-02

Dependency Updates

Removed:

- `pybufrkit` [662](https://github.com/CLIMADA-project/climada_python/pull/662)

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.