<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def log_in(self, username, password):
 """ Logs in to the CouchDB instance with the credentials `username` and `password` """

        self.resource.credentials = (username, password)
        return self.resource.get_json("_session")[2]