Skip to content

BUG: fix Point x/y/z/m attributes to return Python floats#2074

Merged
mwtoews merged 1 commit intoshapely:mainfrom
jorisvandenbossche:fix-point-coord-properties
Jul 7, 2024
Merged

BUG: fix Point x/y/z/m attributes to return Python floats#2074
mwtoews merged 1 commit intoshapely:mainfrom
jorisvandenbossche:fix-point-coord-properties

Conversation

@jorisvandenbossche
Copy link
Copy Markdown
Member

Closes #2070

@coveralls
Copy link
Copy Markdown

coveralls commented Jun 24, 2024

Pull Request Test Coverage Report for Build 9646980112

Details

  • 3 of 4 (75.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.3%) to 88.134%

Changes Missing Coverage Covered Lines Changed/Added Lines %
shapely/geometry/point.py 3 4 75.0%
Totals Coverage Status
Change from base Build 9645569914: 0.3%
Covered Lines: 2622
Relevant Lines: 2975

💛 - Coveralls

Copy link
Copy Markdown
Member

@mwtoews mwtoews left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, it's consistent how (e.g.) .area is handled from the "Y_d" ufuncs.

And I suppose we'll keep the numpy ufunc return types? E.g. shapely.get_x and shapely.area return numpy.float64.

@jorisvandenbossche
Copy link
Copy Markdown
Member Author

And I suppose we'll keep the numpy ufunc return types? E.g. shapely.get_x and shapely.area return numpy.float64.

Yes, for the ufuncs I think we don't want to distinguish based on the input/output dimension, and just let numpy handle that.

@mwtoews mwtoews merged commit 8200a8c into shapely:main Jul 7, 2024
mwtoews added a commit to mwtoews/shapely that referenced this pull request Jul 10, 2024
@mwtoews mwtoews changed the title BUG: fix Point x/y/z/m attribtues to return Python floats BUG: fix Point x/y/z/m attributes to return Python floats Jul 20, 2024
@jorisvandenbossche jorisvandenbossche deleted the fix-point-coord-properties branch July 25, 2024 08:23
@theroggy theroggy added this to the 2.1 milestone Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Type of x, y and z values of a Point are now numpy.float64

4 participants