private void learn() throws IOException, InvalidDimensionsException {
        LearningParameters learningParameters = new LearningParameters();
        learningParameters.setAlpha(new Double(_alfa.getText()));
        learningParameters.setNeighborhood(new Integer(_neighbourhood.getText()));
        _kohonenNetwork.setLearningParametrs(learningParameters);
        _kohonenNetwork.setLearningMode(true);

        CSVReader reader = new CSVReader(new FileReader(_fileChoosenToImport));



        String [] nextLine = reader.readNext();
        LinkedList<double[]> inputs = new LinkedList<double[]>();
        //double[][] inputs = new double[][];

        while (nextLine != null){
            double[] line = new double[nextLine.length];
            for (int k = 0 ; k < nextLine.length; k++){
                line[k] = Double.parseDouble(nextLine[k]);
            }
            inputs.add(line);
            nextLine = reader.readNext();
        }


        for(int i=0;i< new Integer(_iterationCount.getText());i++){
            for (double[] input: inputs){
                _kohonenNetwork.setInputs(input);
                _kohonenNetwork.calculate();
            }
        }

        System.out.println("After learning:");
        _kohonenNetwork.setLearningMode(false);


        for (double[] input: inputs){
            kohonenTest(_kohonenNetwork, input);
        }

    }