Skip to content

Commit

Permalink
Fix testsg
Browse files Browse the repository at this point in the history
  • Loading branch information
mcmahom5 committed Aug 8, 2023
1 parent e87a20a commit 77288f1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/mridle/utilities/process_live_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def get_slt_features_delete_if_ok_to_do_so():

rfs_df = pd.read_csv('/data/mridle/data/silent_live_test/live_files/all/'
'retrospective_reasonforstudy/content/[dbo].[MRIdle_retrospective].csv')
rfs_df[['FillerOrderNo', 'ReasonForStudy']].drop_duplicates()
rfs_df[['FillerOrderNo', 'ReasonForStudy']].drop_duplicates(inplace=True)

# add on proper noshow
ago_st = get_slt_status_data('ago')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -543,6 +543,7 @@ def test_future_appointments_one_row(self):

raw_df = self._fill_out_static_columns(raw_df, create_fon=True)
status_df = build_status_df(raw_df, exclude_patient_ids=[])
status_df['Telefon'] = '0'
feature_df = build_feature_set(status_df, valid_date_range)
cols = [c for c in expected_feature_df.columns.values]
feature_df = feature_df.loc[:, feature_df.columns.isin(cols)]
Expand All @@ -569,6 +570,7 @@ def test_future_appointments_moved_forward(self):

raw_df = self._fill_out_static_columns(raw_df, create_fon=True)
status_df = build_status_df(raw_df, exclude_patient_ids=[])
status_df['Telefon'] = '0'

test_dt = day(2)
feature_df = generate_3_5_days_ahead_features(status_df, test_dt)
Expand Down Expand Up @@ -600,6 +602,7 @@ def test_future_appointments_rescheduled(self):

raw_df = self._fill_out_static_columns(raw_df, create_fon=True)
status_df = build_status_df(raw_df, exclude_patient_ids=[])
status_df['Telefon'] = '0'
feature_df = generate_training_data(status_df, valid_date_range)

cols = [c for c in expected_feature_df.columns.values]
Expand Down Expand Up @@ -701,6 +704,7 @@ def test_multiple_appts(self):
raw_df = pd.concat([raw_df_1, raw_df_2, raw_df_3, raw_df_4], axis=0)

status_df = build_status_df(raw_df, exclude_patient_ids=[])
status_df['Telefon'] = '0'

# Set valid date range to as if we were generating this data on day(12)
test_vdr = [pd.Timestamp(year=2019, month=1, day=1, hour=0, minute=0),
Expand Down Expand Up @@ -780,6 +784,7 @@ def test_appointment_one_row(self):

raw_df = self._fill_out_static_columns(raw_df, create_fon=True)
status_df = build_status_df(raw_df, exclude_patient_ids=[])
status_df['Telefon'] = '0'

model_data_df = generate_training_data(status_df, valid_date_range)

Expand Down Expand Up @@ -887,6 +892,7 @@ def test_multiple_appts(self):
raw_df = pd.concat([raw_df_1, raw_df_2, raw_df_3, raw_df_4], axis=0)

status_df = build_status_df(raw_df, exclude_patient_ids=[])
status_df['Telefon'] = '0'

# Set valid date range to as if we were generating this data on day(12)
test_vdr = [pd.Timestamp(year=2019, month=1, day=1, hour=0, minute=0),
Expand Down

0 comments on commit 77288f1

Please sign in to comment.