Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sdk/python/feast/infra/offline_stores/dask.py
Original file line number Diff line number Diff line change
Expand Up @@ -365,13 +365,13 @@ def evaluate_offline_job():
if start_date and end_date:
source_df = source_df[
source_df[timestamp_field].between(
start_date, end_date, inclusive="left"
start_date, end_date, inclusive="both"
)
]
elif start_date:
source_df = source_df[source_df[timestamp_field] >= start_date]
elif end_date:
source_df = source_df[source_df[timestamp_field] < end_date]
source_df = source_df[source_df[timestamp_field] <= end_date]

source_df = source_df.persist()

Expand Down
2 changes: 1 addition & 1 deletion sdk/python/tests/utils/feature_records.py
Original file line number Diff line number Diff line change
Expand Up @@ -519,7 +519,7 @@ def get_last_feature_row(df: pd.DataFrame, driver_id, max_date: datetime):
"""Manually extract last feature value from a dataframe for a given driver_id with up to `max_date` date"""
filtered = df[
(df["driver_id"] == driver_id)
& (df["event_timestamp"] < max_date.replace(tzinfo=timezone.utc))
& (df["event_timestamp"] <= max_date.replace(tzinfo=timezone.utc))
]
max_ts = filtered.loc[filtered["event_timestamp"].idxmax()]["event_timestamp"]
filtered_by_ts = filtered[filtered["event_timestamp"] == max_ts]
Expand Down
Loading