'Fire an analytics event.
Arguments:
user (User): The user who submitted photos.
event_name (str): Name of the analytics event.
parameters (dict): Event parameters.
Returns: None'

def _fire_event(self, user, event_name, parameters):

    if settings.LMS_SEGMENT_KEY:
        tracking_context = tracker.get_tracker().resolve_context()
        context = {'ip': tracking_context.get('ip'), 'Google    Analytics': {'clientId': tracking_context.get('client_id')}}
        analytics.track(user.id, event_name, parameters, context=context)
