Recent Releases of xarray-dataclasses
xarray-dataclasses - v1.9.1 (2024-12-09)
What's Changed
- Fix project dependencies by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/234
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.9.0...v1.9.1
- Python
Published by astropenguin about 1 year ago
xarray-dataclasses - v1.9.0 (2024-12-09)
What's Changed
- Support Python 3.13 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/232
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.8.0...v1.9.0
- Python
Published by astropenguin about 1 year ago
xarray-dataclasses - v1.8.0 (2024-06-13)
What's Changed
- Release v1.8.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/226
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.7.0...v1.8.0
- Python
Published by astropenguin over 1 year ago
xarray-dataclasses - v1.7.0 (2023-10-16)
What's Changed
- Support Python 3.12 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/217
- Release v1.7.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/219
- Fix dependency specifications by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/221
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.6.0...v1.7.0
- Python
Published by astropenguin over 2 years ago
xarray-dataclasses - v1.6.0 (2023-06-09)
What's Changed
- Fix import of Literal and Protocol by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/203
- Drop support for Python 3.7 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/205
- Release v1.6.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/207
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.5.0...v1.6.0
- Python
Published by astropenguin over 2 years ago
xarray-dataclasses - v1.5.0 (2023-02-02)
What's Changed
- Support Python 3.11 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/190
- Release v1.5.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/192
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.4.0...v1.5.0
- Python
Published by astropenguin about 3 years ago
xarray-dataclasses - v1.4.0 (2023-01-18)
What's Changed
- Remove v2 modules by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/184
- Do not use morecopy by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/186
- Release v1.4.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/188
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.3.2...v1.4.0
- Python
Published by astropenguin about 3 years ago
xarray-dataclasses - v1.3.2 (2023-01-16)
What's Changed
- Add v2 typing module by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/173
- Add v2 specs module by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/175
- Fix importing at the package root by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/180
- Release v1.3.2 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/182
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.3.1...v1.3.2
- Python
Published by astropenguin about 3 years ago
xarray-dataclasses - v1.3.1 (2022-09-05)
This release fixes the name of CITATION file (.ctf → .cff) and package description in README (no code updates).
What's Changed
- Release v1.3.1 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/171
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.3.0...v1.3.1
- Python
Published by astropenguin over 3 years ago
xarray-dataclasses - v1.3.0 (2022-09-05)
What's Changed
- Add specs module by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/163
- Update version range of typing-extensions (>=3.10, <5.0) by @SohumB in https://github.com/astropenguin/xarray-dataclasses/pull/165
- Add support for Poetry >=1.2 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/168
- Release v1.3.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/169
New Contributors
- @SohumB made their first contribution in https://github.com/astropenguin/xarray-dataclasses/pull/165
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.2.0...v1.3.0
- Python
Published by astropenguin over 3 years ago
xarray-dataclasses - v1.2.0 (2022-06-09)
From this release, special type hints (Attr, Coord, Data, Name) can be used within union types.
This would be useful if you want to customize values after dataclass object creation (__post_init__).
The following example automatically sets ranged values to x and y coordinates if they are not specified.
```python import numpy as np from dataclasses import dataclass from typing import Literal, Optional from xarray_dataclasses import AsDataArray, Coord, Data
X = Literal["x"] Y = Literal["y"]
@dataclass class Image(AsDataArray): """2D image as DataArray."""
data: Data[tuple[X, Y], float]
x: Optional[Coord[X, int]] = None
y: Optional[Coord[Y, int]] = None
def __post_init__(self) -> None:
"""Set ranged values to x and y."""
shape = np.shape(self.data)
if self.x is None:
self.x = np.arange(shape[0])
if self.y is None:
self.y = np.arange(shape[1])
```
What's Changed
- Update static type check by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/153
- Update typing module by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/158
- Release v1.2.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/161
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.1.0...v1.2.0
- Python
Published by astropenguin over 3 years ago
xarray-dataclasses - v1.1.0 (2022-04-14)
What's Changed
- README typo: varible by @thewtex in https://github.com/astropenguin/xarray-dataclasses/pull/145
- Add support of Python 3.10 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/149
- Release v1.1.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/151
New Contributors
- @thewtex made their first contribution in https://github.com/astropenguin/xarray-dataclasses/pull/145
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v1.0.0...v1.1.0
- Python
Published by astropenguin almost 4 years ago
xarray-dataclasses - v1.0.0 (2022-03-06)
What's Changed
- Remove deprecated features by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/128
- Update project dependencies by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/130
- Bump ipython from 7.31.0 to 7.31.1 by @dependabot in https://github.com/astropenguin/xarray-dataclasses/pull/134
- Preferentially use data options if they are given in asdata* functions by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/136
- Update data model by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/138
- Release v1.0.0-rc.1 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/140
- Update protocol for public type hints by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/142
- Release v1.0.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/144
New Contributors
- @dependabot made their first contribution in https://github.com/astropenguin/xarray-dataclasses/pull/134
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v0.9.0...v1.0.0
- Python
Published by astropenguin almost 4 years ago
xarray-dataclasses - Update release
What's Changed
- Remove deprecated features by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/128
- Update project dependencies by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/130
- Bump ipython from 7.31.0 to 7.31.1 by @dependabot in https://github.com/astropenguin/xarray-dataclasses/pull/134
- Preferentially use data options if they are given in asdata* functions by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/136
- Update data model by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/138
- Release v1.0.0-rc.1 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/140
New Contributors
- @dependabot made their first contribution in https://github.com/astropenguin/xarray-dataclasses/pull/134
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v0.9.0...v1.0.0-rc.1
- Python
Published by astropenguin about 4 years ago
xarray-dataclasses - Update release
What's Changed
- Assign dim coords to DataArray first by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/117
- Use name-field value as data-variable name by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/118
- Fix mix-in classes by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/122
- Add classmethod to create a shaped array by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/124
- Release v0.9.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/126
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v0.8.0...v0.9.0
- Python
Published by astropenguin about 4 years ago
xarray-dataclasses - Update release
What's Changed
- Add NumPy-like zeros, ones, ... to Dataset class by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/111
- Add data options by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/113
- Release v0.8.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/115
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v0.7.0...v0.8.0
- Python
Published by astropenguin about 4 years ago
xarray-dataclasses - Update release
What's Changed
- Update dev environment by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/103
- Fix type hints that cause errors in static type check by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/106
- Update NumPy-like zeros, ones, ... to be compatible with sizes by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/107
- Update README and docstrings by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/108
- Release v0.7.0 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/110
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v0.6.1...v0.7.0
Future breaking changes from v1.0.0
Please note that the following behavior will change from v1.0.0 due to bug fixes and updates.
Dims and dtype specifications with bare strings will raise NameError
Due to the support of PEP 563, bare strings (i.e. forward references) in a type hint will raise NameError unless the backward type definitions exist. From v1.0.0, for example, the following code will raise NameError.
python
@dataclass
class Image(AsDataArray):
data: Data[tuple["x", "y"], float]
Until v1.0.0, for backward compatibility, such bare strings are forcibly converted to literal type in DataArray or Dataset creation even if backward type definition exists. Since this behavior is not standard in Python, however, we will stop using the workaround from v1.0.0.
To deal with the change, please replace bare strings with literal types in your codes.
python
@dataclass
class Image(AsDataArray):
data: Data[tuple[Literal["x"], Literal["y"]], float]
or define type aliases before the class definition.
```python X = Literal["x"] Y = Literal["y"]
@dataclass class Image(AsDataArray): data: Data[tuple[X, Y], float] ```
- Python
Published by astropenguin about 4 years ago
xarray-dataclasses - Update release
What's Changed
- Remove copy function by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/95
- Use copy function by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/97
- Add marker file for typing by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/99
- Release v0.6.1 by @astropenguin in https://github.com/astropenguin/xarray-dataclasses/pull/101
Full Changelog: https://github.com/astropenguin/xarray-dataclasses/compare/v0.6.0...v0.6.1
- Python
Published by astropenguin over 4 years ago
xarray-dataclasses - Update release
Overview
This release closes the following issues.
- #89 Release v0.6.0
- #85 Update docstrings
- #65 Fix parsing dataclass under future.annotations enabled
Future breaking changes from v1.0.0
Please note that the following behavior will change from v1.0.0 due to bug fixes and updates.
Dims and dtype specifications with bare strings will raise NameError
Due to the support of PEP 563, bare strings (i.e. forward references) in a type hint will raise NameError unless the backward type definitions exist. From v1.0.0, for example, the following code will raise NameError.
python
@dataclass
class Image(AsDataArray):
data: Data[tuple["x", "y"], float]
Until v1.0.0, for backward compatibility, such bare strings are forcibly converted to literal type in DataArray or Dataset creation even if backward type definition exists. Since this behavior is not standard in Python, however, we will stop using the workaround from v1.0.0.
To deal with the change, please replace bare strings with literal types in your codes.
python
@dataclass
class Image(AsDataArray):
data: Data[tuple[Literal["x"], Literal["y"]], float]
or define type aliases before the class definition.
```python X = Literal["x"] Y = Literal["y"]
@dataclass class Image(AsDataArray): data: Data[tuple[X, Y], float] ```
- Python
Published by astropenguin over 4 years ago
xarray-dataclasses - Bug-fix release
This release closes the following issues.
- #86 Fix missing default values for default DataArray and Dataset factories
- Python
Published by astropenguin over 4 years ago
xarray-dataclasses - Update release
This release closes the following issues.
Most updates are related to refactoring. Now AsDataArray.new() and AsDataset.new() are statically typed.
- #82 Release v0.5.0
- #80 Update mix-in classes
- #78 Update typedarray function
- #76 Rename module (parser → datamodel)
- #74 Update parser module
- #71 Refactor typing runtime functions
- #70 Update dataclass type
- #68 Add deprecated module
- #66 Add development container
- #63 Update README
- Python
Published by astropenguin over 4 years ago
xarray-dataclasses - Update release
This release closes the following issues.
- #61 Release v0.4.0
- #59 Add type hints for creating data/coord field from DataArray class
- #56 Update dev environment
- #55 Add new dataclass parser
- #52 Remove verbose or unused internal functions
- #50 Add factory fields for custom DataArray/Dataset creation
- Python
Published by astropenguin over 4 years ago
xarray-dataclasses - Update release
This release closes the following issues/PRs.
- #40 Loosen xarray dependency requirements
- #48 Release v0.3.1
- Python
Published by astropenguin almost 5 years ago
xarray-dataclasses - Update release
Breaking change: Type hinting way has completely changed. Please read README.
This release closes the following issues.
- #24 Add dataset module
- #26 Add Coord and Data types
- #31 Swap the order of dims and dtype in Coord[...] and Data[...]
- #32 Release v0.3.0
- Python
Published by astropenguin almost 5 years ago
xarray-dataclasses - Update release
Breaking change: Python 3.6 support is dropped from this version.
This release closes the following issues.
- #9 Add methods module
- #11 Update typing module
- #14 Add core module
- #17 Update dataarray module
- #20 Add methods to DataArray class
- #22 Release v0.2.0
- Python
Published by astropenguin almost 5 years ago
xarray-dataclasses - Update release
This release closes the following issues.
- #5 Add bases module
- #7 Release v0.1.2
- Python
Published by astropenguin over 5 years ago
xarray-dataclasses - Update release
This release closes the following issues.
- #1 Add typing module
- #3 Release v0.1.1
- Python
Published by astropenguin over 5 years ago