<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def send_batches(self, batch_list):
 """Sends a list of batches to the validator. Args: batch_list (:obj:`BatchList`):
 the list of batches Returns: dict: the json result data, as a dict """

        if isinstance(batch_list, BaseMessage):
            batch_list = batch_list.SerializeToString()

        return self._post('/batches', batch_list)