Recent Releases of PyFES
PyFES - 2026.5.2
Bug Fixes
- Fixed Darwin wave cloning to preserve the dynamic wave type when copying
throughWaveInterfacepointers. TheWave::clone()implementation now
dispatches to a virtualclone_impl()helper, with overrides for derived
classes such asM1andL2so clones keep their concrete type instead
of being sliced toWave.
Performance
- Optimised the
evaluate_tidehot path: faster wave-table indexing,
reduced per-call allocations, vectorised LPE arguments, zero-copy numpy
outputs from the Python bindings, and stack-allocated triangle storage
for the LGP2 mesh interpolation. Median wall-clock improvements versus
2026.4.0, measured on Apple Silicon (arm64): ~-25 % on small Cartesian
batches (10 k-100 k points), ~-5 % on the 1 M-point Cartesian case, and
~-20 % to ~-30 % on LGP2 mesh interpolation across the same range.
Full Changelog: https://github.com/CNES/aviso-fes/compare/2026.4.0...2026.5.2
Hydrosphere - Waves and Currents
- C++
Published by fbriol 8 days ago
PyFES - 2026.4.0
Distribution
- Binary wheels on PyPI: pyfes is now distributed as pre-built wheels for
Linux (manylinux_2_28 x86_64 and aarch64), macOS (arm64, deployment target
13.4) and Windows (x86_64), removing the need to compile Boost, Eigen and
the pybind11 extension locally.pip install pyfesis enough on all
supported platforms. - Python 3.14 and free-threaded 3.14t support: wheels are built for
CPython 3.11, 3.12, 3.13, 3.14 and the free-threaded 3.14t build. - Pre-release routing: PEP 440 pre-release tags (e.g.
2026.4.0rc1,
2026.4.0.dev1) are published to TestPyPI, while plainX.Y.Ztags
go to the real PyPI index, both via OIDC Trusted Publishing.
Build System
- Added a
[tool.cibuildwheel]configuration so wheels can be reproduced
locally withpipx run cibuildwheel. - Switched the Boost lookup to a CONFIG-mode
find_packagewith a manual
boost/version.hppfallback, so builds work with CMake 4.x (which
removedFindBoost.cmake) and with the conda-forgelibboost-headers
package used inside the manylinux container and on Windows. - Forwarded
Python3_EXECUTABLEto pybind11 and set
Python3_FIND_STRATEGY=LOCATIONso each cibuildwheel slot links the
extension against the matching interpreter — fixes a case where the
manylinux image's system Python was selected and produced a wheel with
the wrong ABI tag. - Made the non-editable build path absolute in
setup.pyso
CMAKE_LIBRARY_OUTPUT_DIRECTORYis resolved correctly when CMake runs
from the temporary build directory — fixes the free-threaded 3.14t wheels
that previously shipped without the compiled extension.
Dependencies
- Added
pyyamlto the runtime dependencies (used bypyfes.config).
Full Changelog: https://github.com/CNES/aviso-fes/compare/2026.3.1...2026.4.0
Hydrosphere - Waves and Currents
- C++
Published by fbriol about 1 month ago
PyFES - 2026.3.0
Bug Fixes
- Added case-insensitive NetCDF variable name resolution in the Python
configuration loader (src/pyfes/config.py) to handle constituent
variables such asMSf_amplitudevsMsf_amplitudewhile preserving
exact-match preference and ambiguity detection. - Added case-insensitive NetCDF variable name resolution in the C++ prediction
example (examples/prediction.cpp), with explicit ambiguity checks when
multiple variables differ only by case.
Hydrosphere - Waves and Currents
- C++
Published by fbriol 3 months ago
PyFES - 2026.2.0
[!IMPORTANT]
Major API Changes: This release introduces the PERTH/Doodson prediction
engine and significantly restructures the Python API. Existing code will
require updates. See the Migration Guide below for details.
New Features
- Added PERTH/Doodson prediction engine: Introduced support for the PERTH
tidal prediction engine, which uses Doodson number classification with group
modulations. This engine is compatible with GOT (Goddard Ocean Tide) models
including GOT4.10, GOT5.5, and GOT5.6. The PERTH engine was developed by
Dr. Richard Ray at NASA GSFC and supports 80 tidal constituents. - Dual prediction engine support: The library now supports two prediction
engines:- FES/Darwin Engine: Classical Darwin notation with Schureman nodal
corrections (99 constituents). Compatible with FES2014 and FES2022 atlases. - PERTH/Doodson Engine: Doodson number classification with group
modulations (80 constituents). Compatible with GOT atlases.
- FES/Darwin Engine: Classical Darwin notation with Schureman nodal
- Automatic UTC to TT conversion: The
evaluate_tide()function no longer
requires aleap_secondsparameter. The library now automatically converts
UTC dates to Terrestrial Time (TT) using dynamically updated IERS tables that
include leap second data and Earth rotation parameters (UT1-UTC).
Breaking Changes
-
Restructured Python API: The API has been significantly reorganized:
pyfes.darwinandpyfes.perthsubmodules have been introduced for
engine-specific constituentspyfes.FESSettingsfor FES/Darwin engine configurationpyfes.PerthSettingsfor PERTH/Doodson engine configuration- The generic
pyfes.Settingsclass has been removed
-
Changed
pyfes.config.load()return type: Now returns a
Configurationnamed tuple withmodelsandsettingsattributes
instead of a plain dictionary. -
Changed
evaluate_tide()signature: The function signature has been
simplified. Theleap_secondsparameter has been removed since time
conversion is now automatic. Thenum_threadsparameter has been removed
from the function call and is now configured through thesettingsobject
using the.with_num_threads()method.# Old API tide, lp, flags = pyfes.evaluate_tide( handler['tide'], dates, leap_seconds, lon, lat, settings, num_threads=0 )# New API config = pyfes.config.load('config.yaml') tide, lp, flags = pyfes.evaluate_tide( config.models['tide'], dates, lon, lat, settings=config.settings, ) -
Configuration file changes: Configuration files now support an
engine
parameter to specify which prediction engine to use:tide: lgp: engine: fes # or 'perth5' for GOT models, default is 'fes' path: ${FES_DATA}/ocean_tide.nc # ... other parameters -
Source code reorganization: Python source code has been moved from
src/pyfes/andsrc/core/tosrc/python/pyfes/and
src/python/core/respectively.
Migration Guide
For basic tide evaluation:
Old code (2025.9.0)
import pyfes
import pyfes.config as config_handler
config = config_handler.load('config.yaml')
tide, lp, flags = pyfes.evaluate_tide(
config['tide'],
dates,
leap_secons,
lon,
lat,
settings,
num_threads=0
)
New code (2026.2.0)
import pyfes
config = pyfes.config.load('config.yaml')
tide, lp, flags = pyfes.evaluate_tide(
config.models['tide'],
dates,
lon,
lat,
settings=config.settings,
)
For custom runtime settings
FES/Darwin engine
settings = (
pyfes.FESSettings()
.with_astronomic_formulae(pyfes.Formulae.SCHUREMAN_ORDER_1)
.with_time_tolerance(3600.0)
.with_num_threads(0)
)
PERTH/Doodson engine
settings = (
pyfes.PerthSettings()
.with_group_modulations(True)
.with_inference_type(pyfes.InterpolationType.LINEAR_ADMITTANCE)
.with_astronomic_formulae(pyfes.Formulae.IERS)
.with_num_threads(0)
)
Documentation
- Added comprehensive prediction engines documentation comparing FES/Darwin and
PERTH/Doodson engines. - Added C++ API documentation with examples for both prediction engines.
- Added constituent reference tables with speeds and Doodson numbers.
Bug Fixes
- Fixed bounding box filtering for vertex interpolation in LGP models:
Resolved a bug where vertex interpolation in LGP tidal models didn't properly
handle bounding box constraints. - Fixed Box construction when crossing dateline in LGP mesh triangle
selection: Resolved an issue where bounding box construction failed when
crossing the international dateline. - Improved NetCDF reading performance: Enhanced performance by loading
selected indices directly rather than loading all elements before subsampling.
Testing
- Added comprehensive test coverage for leap seconds handling.
- Added pickle serialization tests for configuration objects.
Build System
- Reorganized source directory structure for clearer separation of Python
bindings.
Hydrosphere - Waves and Currents
- C++
Published by fbriol 3 months ago
PyFES - 2025.9.0
🔥Git History Rewritten: The git history has been rewritten to remove git
LFS files. The test dataset is now hosted on osf.io and downloaded
automatically during testing. Existing clones of the repository must be
deleted and cloned again to avoid conflicts and ensure proper operation.
New Features
- Improved LGP extrapolation algorithm: Previously, extrapolation for points
outside the LGP mesh only used the single closest vertex. The new algorithm
now considers multiple vertices within the maximum allowed distance, applying
inverse distance weighting based on all nearby vertices. This provides
smoother transitions in extrapolated regions and more accurate results near
mesh boundaries. The quality flag reflects this change by returning a negative
value equal to the number of vertices used in the extrapolation (limited to
-127). - Enhanced quality flag reporting: The quality flag now provides more
detailed information for extrapolated values. A negative flag (e.g., -3)
indicates that the value was extrapolated using that number of vertices (e.g.,
3). This allows for a more precise assessment of data quality in extrapolated
regions, particularly for LGP meshes. See the Breaking Changes section for
details on the updated quality flag semantics. - Updated documentation: The API documentation has been updated to reflect
the new quality flag semantics and the improved LGP extrapolation algorithm. - Added new tidal constituents: M1, M11, M12, M13, N2P, and L2P, with
corresponding formulas, classes, and updates to constituent and wave handling. - Enhanced Wave class to support initialization with Darwin parameters using a
new Darwin builder pattern. - Implemented IERS formula for astronomical angle calculations and added related
tests. - Added
arcsecondsfunction to convert angles from arcseconds to radians.
Breaking Changes
-
Removed the Quality enum: The
pyfes.Qualityenum has been removed
from the public API. Quality flags are now returned as integer values instead
of enum constants.pyfes.Quality.kUndefined(0) →0pyfes.Quality.kExtrapolated1(1) →-1(negative values indicate
extrapolation)pyfes.Quality.kExtrapolated2(2) →-2pyfes.Quality.kExtrapolated3(3) →-3pyfes.Quality.kInterpolated(4) → positive values (indicate
interpolation using N data points)
-
Updated quality flag semantics: Quality flags returned by interpolation
functions now use a more intuitive system:0: Value is undefined (no data available)- Positive values: Value is interpolated using :math:
Ndata points
(where :math:Nequals the quality flag value) - Negative values: Value is extrapolated using :math:
\lvert N\rvert
data points (where :math:\lvert N\rvertequals the absolute value)
-
API signature changes: Functions that previously returned
Quality
enum values now returnint8_torVectorInt8types. This affects:evaluate_tide()return type changed fromVectorQualityto
VectorInt8AbstractTidalModel.interpolate()methods now returnintinstead of
Quality
-
Removed documentation: The
pyfes.core.Qualityclass documentation has
been removed from the API reference.
Migration Guide
For quality flag checking in user code:
# Old code
if quality == pyfes.Quality.kUndefined:
# handle undefined
elif quality == pyfes.Quality.kInterpolated:
# handle interpolated
elif quality in [pyfes.Quality.kExtrapolated1, pyfes.Quality.kExtrapolated2, pyfes.Quality.kExtrapolated3]:
# handle extrapolated
# New code
if quality == 0:
# handle undefined
elif quality > 0:
# handle interpolated (quality = number of data points used)
elif quality < 0:
# handle extrapolated (abs(quality) = number of data points used)
For filtering interpolated vs extrapolated values:
# Old code
interpolated_mask = (quality == pyfes.Quality.kInterpolated)
# New code
interpolated_mask = (quality > 0)
Bug Fixes
- Corrected mean_c20 and mean_c30 calculations for mass conservation in long
period equilibrium. - Updated expected values in tide tests for improved accuracy.
- Fixed handling of NaN values in Cartesian interpolation by resetting to
undefined. - Updated frequency documentation to reflect correct units in
wave.hppand
wave_table.py. - Updated copyright year in LICENSE and corrected license type in
setup.cfg.
Documentation
- Improved documentation for formulae, wave constructors, and frequency units
for clarity and consistency.
Build System
- Updated pre-commit hook versions for pyupgrade and clang-format.
Testing
- Added tests for new wave constituents and additional assertions for IERS
astronomical angle calculations.
Hydrosphere - Waves and Currents
- C++
Published by fbriol 9 months ago
PyFES - Test Dataset v1.0.0
Test dataset for AVISO-FES validation
Hydrosphere - Waves and Currents
- C++
Published by fbriol 10 months ago
PyFES - 2025.2.0
Bug Fixes
- Fix the calculation of the quality flag from LGP models
New Features
- Add evaluate_equilibrium_long_period function to the API
- Remove excluded constituents parameter from Settings class and related functions
- Allow dates before January 1st, 1972 to determine the leap seconds between TAI/UTC. In this case, a user warning is thrown and the leap seconds are set to 0.
Documentation
- enhance documentation and add examples for the LGP discretization
Miscellaneous
- Refactor type hinting and improve code clarity with TYPE_CHECKING imports
Full Changelog: https://github.com/CNES/aviso-fes/compare/2025.1.0...2025.2.0
Hydrosphere - Waves and Currents
- C++
Published by fbriol over 1 year ago
PyFES - 2024.6.0
New code and Python library designed to handle the new finite element grids of FES2022.
Full Changelog: https://github.com/CNES/aviso-fes/compare/2.9.7...2024.6.0
Hydrosphere - Waves and Currents
- C++
Published by fbriol almost 2 years ago
PyFES - 2.9.7
Release Notes for Version 2.9.7
Updates & Refactorings
- Updated the FES example to the latest library version. This ensures compatibility and leverages the latest features and improvements of the library.
- Exclude
MSF_LPfrom the long-period equilibrium wave calculation routine (lpe_minus_n_waves) because it is already included in the MSF atlas with FES2022.
Features
- Introduced a new keyword to optionally disable wave computation by admittance and in the long-period equilibrium wave calculation routine (
lpe_minus_n_waves).
Fixes
- Fixed the tide type for the "MSF" wave in
prediction.cto correct a previously incorrect tide type setting.
Maintenance
- Updated version to 2.9.7 in
conda/meta.yamlandinclude/fes.hto align with the current release.
This release includes several important updates and improvements aimed at enhancing the functionality, accuracy, and usability of the FES library.
Hydrosphere - Waves and Currents
- C++
Published by fbriol almost 2 years ago