nakas Claude commited on
Commit
2bd7691
·
1 Parent(s): 7f2f72d

Fix indentation error in process_daily_snow function

Browse files

Fixed IndentationError at line 161 where the function body was not properly indented after the function definition.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

Files changed (1) hide show
  1. app.py +10 -9
app.py CHANGED
@@ -157,16 +157,17 @@ def calculate_total_new_snow(df):
157
  snow_df['day_group'] = snow_df['datetime'].apply(
158
  lambda x: x.date() if x.hour >= 9 else (x - pd.Timedelta(days=1)).date()
159
  )
 
160
  def process_daily_snow(group):
161
- """Sum up ONLY the 3-hour snowfall amounts for each day period"""
162
- # Sort by time to ensure proper sequence
163
- group = group.sort_values('datetime')
164
-
165
- # Sum only the valid 3-hour amounts, treating NaN as 0
166
- valid_amounts = group['snowfall_3hr'].fillna(0)
167
- daily_total = valid_amounts.sum()
168
-
169
- return daily_total
170
 
171
  def create_plots(df):
172
  """Create all weather plots including SWE estimates"""
 
157
  snow_df['day_group'] = snow_df['datetime'].apply(
158
  lambda x: x.date() if x.hour >= 9 else (x - pd.Timedelta(days=1)).date()
159
  )
160
+
161
  def process_daily_snow(group):
162
+ """Sum up ONLY the 3-hour snowfall amounts for each day period"""
163
+ # Sort by time to ensure proper sequence
164
+ group = group.sort_values('datetime')
165
+
166
+ # Sum only the valid 3-hour amounts, treating NaN as 0
167
+ valid_amounts = group['snowfall_3hr'].fillna(0)
168
+ daily_total = valid_amounts.sum()
169
+
170
+ return daily_total
171
 
172
  def create_plots(df):
173
  """Create all weather plots including SWE estimates"""