James McCool
commited on
Commit
·
43f4453
1
Parent(s):
a92df2e
Remove type conversion for 'Own' column in predict_dupes function and add debug print statement to display the first 10 rows of the working frame, aiding in data verification.
Browse files
app.py
CHANGED
|
@@ -953,10 +953,11 @@ with tab2:
|
|
| 953 |
sum(st.session_state['map_dict']['own_map'].get(player, 0) for player in row.iloc[1:]),
|
| 954 |
axis=1
|
| 955 |
)
|
| 956 |
-
st.session_state['working_frame']['Own'] = st.session_state['working_frame']['Own'].astype('float32')
|
| 957 |
st.session_state['working_frame']['median'] = st.session_state['working_frame']['median'].astype('float32')
|
| 958 |
st.session_state['working_frame']['salary'] = st.session_state['working_frame']['salary'].astype('uint16')
|
| 959 |
|
|
|
|
| 960 |
st.session_state['base_frame'] = predict_dupes(st.session_state['working_frame'], st.session_state['map_dict'], site_var, type_var, Contest_Size, strength_var, sport_var)
|
| 961 |
st.session_state['working_frame'] = st.session_state['base_frame'].copy()
|
| 962 |
# st.session_state['highest_owned_teams'] = st.session_state['projections_df'][~st.session_state['projections_df']['position'].isin(['P', 'SP'])].groupby('team')['ownership'].sum().sort_values(ascending=False).head(3).index.tolist()
|
|
|
|
| 953 |
sum(st.session_state['map_dict']['own_map'].get(player, 0) for player in row.iloc[1:]),
|
| 954 |
axis=1
|
| 955 |
)
|
| 956 |
+
# st.session_state['working_frame']['Own'] = st.session_state['working_frame']['Own'].astype('float32')
|
| 957 |
st.session_state['working_frame']['median'] = st.session_state['working_frame']['median'].astype('float32')
|
| 958 |
st.session_state['working_frame']['salary'] = st.session_state['working_frame']['salary'].astype('uint16')
|
| 959 |
|
| 960 |
+
print(st.session_state['working_frame'].head(10))
|
| 961 |
st.session_state['base_frame'] = predict_dupes(st.session_state['working_frame'], st.session_state['map_dict'], site_var, type_var, Contest_Size, strength_var, sport_var)
|
| 962 |
st.session_state['working_frame'] = st.session_state['base_frame'].copy()
|
| 963 |
# st.session_state['highest_owned_teams'] = st.session_state['projections_df'][~st.session_state['projections_df']['position'].isin(['P', 'SP'])].groupby('team')['ownership'].sum().sort_values(ascending=False).head(3).index.tolist()
|