You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

Started June 3, 2019


Steps in running model

  • get weather data from source
    • cron running on arcus.sws.uiuc.edu
    • data 2 days behind current date
    • verified  
  • daily weather
    • convert to cm and celsius
    • average min and max temps
    • put into year-month-week dictionary
    • (verified  )
  • calculate_seasonal_weather
    • seasons
      • winter 
    • believe there is a problem with seasons


calculate_seasonal_weather
before
        for epi_week in weekly_weather[epi_year]:

            if count_years > 1:
                if 1 <= epi_week <= 9:
                    seasonal_weather[epi_year]["winter"]["degree_week_average_c"] += weekly_weather[epi_year-1][epi_week]["degree_week_c"]
                    seasonal_weather[epi_year]["winter"]["precip_week_average_cm"] += weekly_weather[epi_year-1][epi_week]["precip_cm"]
                if 49 <= epi_week <= 52:
                    seasonal_weather[epi_year]["winter"]["degree_week_average_c"] += weekly_weather[epi_year][epi_week]["degree_week_c"]
                    seasonal_weather[epi_year]["winter"]["precip_week_average_cm"] += weekly_weather[epi_year][epi_week]["precip_cm"]
            if 23 <= epi_week <= 35:
                seasonal_weather[epi_year]["summer"]["degree_week_average_c"] += weekly_weather[epi_year][epi_week]["degree_week_c"]
                seasonal_weather[epi_year]["summer"]["precip_week_average_cm"] += weekly_weather[epi_year][epi_week]["precip_cm"]
            if 10 <= epi_week <= 22:
                seasonal_weather[epi_year]["spring"]["degree_week_average_c"] += weekly_weather[epi_year][epi_week]["degree_week_c"]
                seasonal_weather[epi_year]["spring"]["precip_week_average_cm"] += weekly_weather[epi_year][epi_week]["precip_cm"]
            if 36 <= epi_week <= 48:
                seasonal_weather[epi_year]["fall"]["degree_week_average_c"] += weekly_weather[epi_year][epi_week]["degree_week_c"]
                seasonal_weather[epi_year]["fall"]["precip_week_average_cm"] += weekly_weather[epi_year][epi_week]["precip_cm"]


  • No labels