def get(self, *args, **kwargs):
clone = self.filter(*args, **kwargs)<EOL>num = len(clone)<EOL>if num == <NUM_LIT:1>:<EOL><INDENT>return clone._result_cache[<NUM_LIT:0>]<EOL><DEDENT>if not num:<EOL><INDENT>raise self.model.DoesNotExist(<EOL>"<STR_LIT>"<EOL>"<STR_LIT>" %<EOL>(self.model.__class__.__name__, kwargs))<EOL><DEDENT>raise self.model.MultipleObjectsReturned(<EOL>"<STR_LIT>"<EOL>"<STR_LIT>" %<EOL>(self.model.__class__.__name__, num, kwargs))<EOL>
Performs the query and returns a single object matching the given
keyword arguments.