From d18bab1e0e1891dfe70da0c209c831ebd03868aa Mon Sep 17 00:00:00 2001 From: Mehdi Ataei Date: Thu, 31 Oct 2024 12:16:36 -0400 Subject: [PATCH] Added changelog --- CHANGELOG.md | 2 ++ xlb/operator/stepper/stepper.py | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1d036de..69ad1f4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,3 +18,5 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - XLB is now installable via pip - Complete rewrite of the codebase for better modularity and extensibility based on "Operators" design pattern - Added NVIDIA's Warp backend for state-of-the-art performance +- Added abstraction layer for boundary condition efficient encoding/decoding of auxiliary data +- Added the capability to add profiles to boundary conditions \ No newline at end of file diff --git a/xlb/operator/stepper/stepper.py b/xlb/operator/stepper/stepper.py index 44aab5f..b28ac7f 100644 --- a/xlb/operator/stepper/stepper.py +++ b/xlb/operator/stepper/stepper.py @@ -13,6 +13,11 @@ def __init__(self, operators, boundary_conditions): from xlb.operator.boundary_condition.boundary_condition_registry import boundary_condition_registry self.operators = operators + + for bc in boundary_conditions: + if bc.needs_aux_init and not bc.is_initialized_with_aux_data: + raise RuntimeError(f"Boundary condition {bc.__class__.__name__} requires auxiliary data initialization but was not initialized") + self.boundary_conditions = boundary_conditions # Get velocity set, precision policy, and compute backend