def set_optional_attr(in_args, classifier):
    """
    This function applies all the optional commandline arguments. This is designed to
    call after the instantiation of classifier object

    Parameters:
        in_args - This is parsed command line arguments
        classifier - This is an object of type Flower_Classifier. All the optional
                   attributes of this object will be set using setters.
    Return:
        classifier - Classifer object will the optional attributes set to it.
    """
    if in_args.save_dir != None:
        classifier.save_dir = in_args.save_dir
    if in_args.learning_rate != None:
        classifier.learning_rate = in_args.learning_rate
    if in_args.hidden_units != None:
        classifier.hidden_units = in_args.hidden_units
    if in_args.epochs != None:
        classifier.epochs = in_args.epochs
    if in_args.gpu != None:
        classifier.gpu = in_args.gpu
    return classifier