brainandforce / Electrum.jl

A Julian toolkit for solid-state chemical theory.
MIT License
31 stars 0 forks source link

Fixed broken colon indexing, `axes()`, and `iterate()` for `RealSpaceDataGrid` #136

Closed brainandforce closed 1 year ago

brainandforce commented 1 year ago

This should leave RealSpaceDataGrid with correct iteration, handling of colons in getindex(), and modulo calculations. Xtal.reinterpret_index() can now be used as a general way to convert indices for use

This also changes the behavior of grid() so that it creates a copy of the backing grid rather than returning the original. This means I'll need to update some grid() calls so that they are direct struct calls now.

codecov[bot] commented 1 year ago

Codecov Report

Base: 32.47% // Head: 32.23% // Decreases project coverage by -0.23% :warning:

Coverage data is based on head (4ecf548) compared to base (c387809). Patch coverage: 27.77% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #136 +/- ## ========================================== - Coverage 32.47% 32.23% -0.24% ========================================== Files 16 16 Lines 1398 1402 +4 ========================================== - Hits 454 452 -2 - Misses 944 950 +6 ``` | [Impacted Files](https://codecov.io/gh/brainandforce/Xtal.jl/pull/136?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores) | Coverage Δ | | |---|---|---| | [src/Xtal.jl](https://codecov.io/gh/brainandforce/Xtal.jl/pull/136?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores#diff-c3JjL1h0YWwuamw=) | `50.00% <ø> (ø)` | | | [src/filetypes.jl](https://codecov.io/gh/brainandforce/Xtal.jl/pull/136?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores#diff-c3JjL2ZpbGV0eXBlcy5qbA==) | `41.47% <0.00%> (ø)` | | | [src/data/reciprocalspace.jl](https://codecov.io/gh/brainandforce/Xtal.jl/pull/136?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores#diff-c3JjL2RhdGEvcmVjaXByb2NhbHNwYWNlLmps) | `13.60% <17.64%> (-2.53%)` | :arrow_down: | | [src/data/realspace.jl](https://codecov.io/gh/brainandforce/Xtal.jl/pull/136?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores#diff-c3JjL2RhdGEvcmVhbHNwYWNlLmps) | `30.55% <24.00%> (-3.70%)` | :arrow_down: | | [src/math.jl](https://codecov.io/gh/brainandforce/Xtal.jl/pull/136?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores#diff-c3JjL21hdGguamw=) | `44.44% <44.44%> (ø)` | | | [src/data/fft.jl](https://codecov.io/gh/brainandforce/Xtal.jl/pull/136?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores#diff-c3JjL2RhdGEvZmZ0Lmps) | `66.66% <100.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Brandon+Flores)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.