Skip to content

Commit

Permalink
Merge pull request #355 from nyx-space/dependabot/cargo/polars-0.45.1
Browse files Browse the repository at this point in the history
Update polars requirement from 0.43.1 to 0.45.1
  • Loading branch information
ChristopherRabotin authored Dec 10, 2024
2 parents c1b8477 + f89526c commit faf8226
Show file tree
Hide file tree
Showing 11 changed files with 30 additions and 35 deletions.
12 changes: 4 additions & 8 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ permissions:

jobs:
linux:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
strategy:
matrix:
target: [x86_64, x86, aarch64, armv7, ppc64le]
Expand All @@ -30,17 +30,13 @@ jobs:
wget -O data/pck08.pca http://public-data.nyxspace.com/anise/v0.5/pck08.pca
wget -O data/pck11.pca http://public-data.nyxspace.com/anise/v0.5/pck11.pca
- uses: actions/setup-python@v5
- name: Setup Python 3.9 on ${{ matrix.target }}
uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Fix openssl regression
run: cargo update openssl-src --precise 300.3.1+3.3.1

python-version: "3.9"

- name: Build wheels
uses: PyO3/maturin-action@v1
continue-on-error: ${{ matrix.target == 's390x' }}
with:
target: ${{ matrix.target }}
args: --release --out dist --find-interpreter
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ exclude = [
]

[workspace.dependencies]
hifitime = "4.0.0"
hifitime = "4.0.1"
memmap2 = "0.9.4"
crc32fast = "1.4.2"
der = { version = "0.7.8", features = ["derive", "alloc", "real"] }
Expand Down
4 changes: 2 additions & 2 deletions anise-py/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[build-system]
requires = ["maturin>=1.4,<2.0"]
requires = ["maturin>=1.7,<2.0"]
build-backend = "maturin"

[project]
name = "anise"
requires-python = ">=3.8"
requires-python = ">=3.9,<3.13"
classifiers = [
"Programming Language :: Rust",
"Programming Language :: Python :: Implementation :: CPython",
Expand Down
2 changes: 1 addition & 1 deletion anise/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ parquet = "53.0.0"
arrow = "53.0.0"
criterion = "0.5"
iai = "0.1"
polars = { version = "0.43.1", features = ["lazy", "parquet"] }
polars = { version = "0.45.1", features = ["lazy", "parquet"] }
rayon = "1.7"
serde_yaml = "0.9.30"

Expand Down
2 changes: 1 addition & 1 deletion anise/src/math/interpolation/hermite.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ use super::{InterpolationError, MAX_SAMPLES};
/// # Runtime verifications
/// 1. Ensure that all provided arrays are of the same size.
/// 2. Ensure that there are no more than 32 items to interpolate.
/// 3. Ensure no division by zero errors (zero is set to core::f64::EPSILON, which is about 2e-16).
/// 3. Ensure no division by zero errors (zero is set to f64::EPSILON, which is about 2e-16).
pub fn hermite_eval(
xs: &[f64],
ys: &[f64],
Expand Down
1 change: 0 additions & 1 deletion anise/src/naif/daf/data_types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ use pyo3::prelude::*;
#[cfg_attr(feature = "python", pyclass)]
#[derive(Copy, Clone, Debug, PartialEq)]
#[repr(u8)]

pub enum DataType {
Type1ModifiedDifferenceArray = 1,
Type2ChebyshevTriplet = 2,
Expand Down
8 changes: 4 additions & 4 deletions anise/src/naif/daf/datatypes/chebyshev.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ pub struct Type2ChebyshevSet<'a> {
pub record_data: &'a [f64],
}

impl<'a> Type2ChebyshevSet<'a> {
impl Type2ChebyshevSet<'_> {
pub fn degree(&self) -> usize {
(self.rsize - 2) / 3 - 1
}
Expand Down Expand Up @@ -59,7 +59,7 @@ impl<'a> Type2ChebyshevSet<'a> {
}
}

impl<'a> fmt::Display for Type2ChebyshevSet<'a> {
impl fmt::Display for Type2ChebyshevSet<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down Expand Up @@ -236,13 +236,13 @@ pub struct Type2ChebyshevRecord<'a> {
pub z_coeffs: &'a [f64],
}

impl<'a> Type2ChebyshevRecord<'a> {
impl Type2ChebyshevRecord<'_> {
pub fn midpoint_epoch(&self) -> Epoch {
Epoch::from_et_seconds(self.midpoint_et_s)
}
}

impl<'a> fmt::Display for Type2ChebyshevRecord<'a> {
impl fmt::Display for Type2ChebyshevRecord<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down
8 changes: 4 additions & 4 deletions anise/src/naif/daf/datatypes/chebyshev3.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ pub struct Type3ChebyshevSet<'a> {
pub record_data: &'a [f64],
}

impl<'a> Type3ChebyshevSet<'a> {
impl Type3ChebyshevSet<'_> {
pub fn degree(&self) -> usize {
(self.rsize - 2) / 6 - 1
}
Expand Down Expand Up @@ -59,7 +59,7 @@ impl<'a> Type3ChebyshevSet<'a> {
}
}

impl<'a> fmt::Display for Type3ChebyshevSet<'a> {
impl fmt::Display for Type3ChebyshevSet<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down Expand Up @@ -245,13 +245,13 @@ pub struct Type3ChebyshevRecord<'a> {
pub vz_coeffs: &'a [f64],
}

impl<'a> Type3ChebyshevRecord<'a> {
impl Type3ChebyshevRecord<'_> {
pub fn midpoint_epoch(&self) -> Epoch {
Epoch::from_et_seconds(self.midpoint_et_s)
}
}

impl<'a> fmt::Display for Type3ChebyshevRecord<'a> {
impl fmt::Display for Type3ChebyshevRecord<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down
6 changes: 3 additions & 3 deletions anise/src/naif/daf/datatypes/hermite.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ pub struct HermiteSetType12<'a> {
pub record_data: &'a [f64],
}

impl<'a> fmt::Display for HermiteSetType12<'a> {
impl fmt::Display for HermiteSetType12<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down Expand Up @@ -149,13 +149,13 @@ pub struct HermiteSetType13<'a> {
pub epoch_registry: &'a [f64],
}

impl<'a> HermiteSetType13<'a> {
impl HermiteSetType13<'_> {
pub fn degree(&self) -> usize {
2 * self.samples - 1
}
}

impl<'a> fmt::Display for HermiteSetType13<'a> {
impl fmt::Display for HermiteSetType13<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down
4 changes: 2 additions & 2 deletions anise/src/naif/daf/datatypes/lagrange.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ pub struct LagrangeSetType8<'a> {
pub record_data: &'a [f64],
}

impl<'a> fmt::Display for LagrangeSetType8<'a> {
impl fmt::Display for LagrangeSetType8<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down Expand Up @@ -145,7 +145,7 @@ pub struct LagrangeSetType9<'a> {
pub epoch_registry: &'a [f64],
}

impl<'a> fmt::Display for LagrangeSetType9<'a> {
impl fmt::Display for LagrangeSetType9<'_> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
write!(
f,
Expand Down
16 changes: 8 additions & 8 deletions anise/tests/ephemerides/transform.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ fn de440s_transform_verif_venus2emb() {
relative_eq!(
state_rtn.radius_km,
-state.radius_km,
epsilon = core::f64::EPSILON
epsilon = f64::EPSILON
),
"pos = {}\nexp = {}\nerr = {:e}",
state_rtn.radius_km,
Expand All @@ -161,7 +161,7 @@ fn de440s_transform_verif_venus2emb() {
relative_eq!(
state_rtn.velocity_km_s,
-state.velocity_km_s,
epsilon = core::f64::EPSILON
epsilon = f64::EPSILON
),
"vel = {}\nexp = {}\nerr = {:e}",
state.velocity_km_s,
Expand Down Expand Up @@ -400,12 +400,12 @@ fn validate_gh_283_multi_barycenter_and_los(almanac: Almanac) {
let spice_occult = spice::occult(
front,
fshape,
&fframe,
&back,
&bshape,
&bframe,
&abcorr,
&obsrvr,
fframe,
back,
bshape,
bframe,
abcorr,
obsrvr,
epoch.to_et_seconds(),
);

Expand Down

0 comments on commit faf8226

Please sign in to comment.