<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def Execute(self, http, sleep_between_polls=5, max_retries=5, max_batch_size=None, batch_request_callback=None):
 """Execute all of the requests in the batch. Args: http: httplib2.Http object for use in the request. sleep_between_polls: Integer number of seconds to sleep between polls. max_retries: Max retries. Any requests that have not succeeded by this number of retries simply report the last response or exception, whatever it happened to be. max_batch_size: int, if specified requests will be split in batches of given size. batch_request_callback: function of (http_response, exception) passed to BatchHttpRequest which will be run on any given results. Returns: List of ApiCalls. """

        requests = [request for request in self.api_requests
                    if not request.terminal_state]
        batch_size = max_batch_size or len(requests)

        for attempt in range(max_retries):
            if attempt:
                time.sleep(sleep_between_polls)

            for i in range(0, len(requests), batch_size):
                # Create a batch_http_request object and populate it with
                # incomplete requests.
                batch_http_request = BatchHttpRequest(
                    batch_url=self.batch_url,
                    callback=batch_request_callback,
                    response_encoding=self.response_encoding
                )
                for request in itertools.islice(requests,
                                                i, i + batch_size):
                    batch_http_request.Add(
                        request.http_request, request.HandleResponse)
                batch_http_request.Execute(http)

                if hasattr(http.request, 'credentials'):
                    if any(request.authorization_failed
                           for request in itertools.islice(requests,
                                                           i, i + batch_size)):
                        http.request.credentials.refresh(http)

            # Collect retryable requests.
            requests = [request for request in self.api_requests if not
                        request.terminal_state]
            if not requests:
                break

        return self.api_requests