'Returns an instance of the serializer class'

@property
def serializer(self):

    serializer_class = self.serializer_class
    kwargs = {}
    if (getattr(self, 'aggregated_activity_class', None) is not None):
        kwargs['aggregated_activity_class'] = self.aggregated_activity_class
    serializer_instance = serializer_class(self.model, activity_class=self.activity_class, **kwargs)
    return serializer_instance
