def fit_predict(self,
                    Gtr,
                    Ytr,
                    Gt,
                    Yt,
                    grid_search,
                    acc_param="F1Mean",
                    RS=0,
                    VERBOSE=False):
        """Learn the model on training dataset and predict on the testing dataset.
        
        Input:
            - Gtr (array): training subset
            - Ytr (array): true labels of training subset
            - Gt (array): testing subset
            - Yt (array): true labels of testing subset
            - grid_search (dict): grid search for the CV
            - acc (str): accuracy parameter for the cross-validation (default "F1Mean", otherwise it will be the OA)
            - RS (int) : random seed used for the stratified k-fold CV
            - VERBOSE (bool): verbose (default: False)
        
        Return:
            - confMatrix (object ConfusionMatrix): confusion matrix issued from the classification
            - yp (array): vector of predicted labels of the testing subset
            - grid.best_params_ (dict): combination of parameters that gave the best results during the CV
        
        TODO: implement own scoring parameter
        """

        if acc_param == "F1Mean":
            score = 'f1_macro'
        else:
            score = 'accuracy'

        ## Initialization of the stratifield K-CV
        cv = StratifiedKFold(Ytr, n_folds=self.n_folds, random_state=RS)

        #Implementation of a fit and a predict methods with parameters from grid search
        grid = GridSearchCV(self.pipe,
                            param_grid=grid_search,
                            scoring=score,
                            verbose=VERBOSE,
                            cv=cv,
                            n_jobs=3)
        grid.fit(Gtr, Ytr)

        model = grid.best_estimator_
        if VERBOSE:
            print grid.best_score_

        #Learn model
        model.fit(Gtr, Ytr)  #could use refit in version 0.19 of sklearn
        #Predict
        yp = model.predict(Gt)

        #Compute confusion matrix
        confMatrix = ConfusionMatrix()
        confMatrix.compute_confusion_matrix(yp, Yt)

        return confMatrix, yp, grid.best_params_