Record the number of PRESENT vs NOT_FOUND feature values for a feature view.
(
feature_view_name: str, present_count: int, not_found_count: int
)
| 374 | |
| 375 | |
| 376 | def track_feature_statuses( |
| 377 | feature_view_name: str, present_count: int, not_found_count: int |
| 378 | ): |
| 379 | """Record the number of PRESENT vs NOT_FOUND feature values for a feature view.""" |
| 380 | if not _config.online_features: |
| 381 | return |
| 382 | if present_count > 0: |
| 383 | online_features_status_total.labels( |
| 384 | feature_view=feature_view_name, status="present" |
| 385 | ).inc(present_count) |
| 386 | if not_found_count > 0: |
| 387 | online_features_status_total.labels( |
| 388 | feature_view=feature_view_name, status="not_found" |
| 389 | ).inc(not_found_count) |
| 390 | |
| 391 | |
| 392 | def track_transformation(odfv_name: str, mode: str, duration_seconds: float): |