<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _find_rankings(self, year):
 """ Retrieve the rankings for each week. Find and retrieve all AP rankings for the requested year and combine them on a per-week basis. Each week contains information about the name, abbreviation, rank, movement, and previous rank for each team as well as the date and week number the results were published on. Parameters year : string A string of the requested year to pull rankings from. """

        if not year:
            year = utils._find_year_for_season('ncaaf')
        page = self._pull_rankings_page(year)
        if not page:
            output = ("Can't pull rankings page. Ensure the following URL "
                      "exists: %s" % RANKINGS_URL)
            raise ValueError(output)
        rankings = page('table#ap tbody tr').items()
        weekly_rankings = []
        week = 0
        for team in rankings:
            if 'class="thead"' in str(team):
                self._rankings[int(week)] = weekly_rankings
                weekly_rankings = []
                continue
            abbreviation, name = self._get_team(team)
            rank = utils._parse_field(RANKINGS_SCHEME, team, 'rank')
            week = utils._parse_field(RANKINGS_SCHEME, team, 'week')
            date = utils._parse_field(RANKINGS_SCHEME, team, 'date')
            previous = utils._parse_field(RANKINGS_SCHEME, team, 'previous')
            change = utils._parse_field(RANKINGS_SCHEME, team, 'change')
            if 'decrease' in str(team(RANKINGS_SCHEME['change'])):
                change = int(change) * -1
            elif 'increase' in str(team(RANKINGS_SCHEME['change'])):
                try:
                    change = int(change)
                except ValueError:
                    change = 0
            else:
                change = 0
            rank_details = {
                'abbreviation': abbreviation,
                'name': name,
                'rank': int(rank),
                'week': int(week),
                'date': date,
                'previous': previous,
                'change': change
            }
            weekly_rankings.append(rank_details)
        # Add the final rankings which is not terminated with another header
        # row and hence will not hit the first if statement in the loop above.
        self._rankings[int(week)] = weekly_rankings