Annikaijak commited on
Commit
b37d5ad
·
verified ·
1 Parent(s): bbe6bc3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -1
app.py CHANGED
@@ -80,9 +80,16 @@ with tab1:
80
  return 0
81
  else:
82
  return value
 
 
 
 
 
 
83
 
84
  building_mag_prediction_data['et0_fao_evapotranspiration'] = building_mag_prediction_data['et0_fao_evapotranspiration'].apply(fill_nan_with_zero)
85
-
 
86
  st.dataframe(building_mag_prediction_data)
87
 
88
  # Making the predictions and getting the latest data
 
80
  return 0
81
  else:
82
  return value
83
+
84
+ def add_small_value_if_zero(value):
85
+ if value == 0:
86
+ return value + 0.0001
87
+ else:
88
+ return value
89
 
90
  building_mag_prediction_data['et0_fao_evapotranspiration'] = building_mag_prediction_data['et0_fao_evapotranspiration'].apply(fill_nan_with_zero)
91
+ building_mag_prediction_data['et0_fao_evapotranspiration'] = building_mag_prediction_data['et0_fao_evapotranspiration'].apply(add_small_value_if_zero)
92
+
93
  st.dataframe(building_mag_prediction_data)
94
 
95
  # Making the predictions and getting the latest data