Exemple #1
0
        private InferenceLayer <LinearMembershipFunction> Create()
        {
            var lrate = 1e-2;
            var smoothingAvarageRate = 1e-3;

            var ruleset = new FirstLevelRuleset(5e-1);

            var termLayer1 = new TermLayer <LinearMembershipFunction>(learningRate: lrate,
                                                                      smoothingAverageRate: smoothingAvarageRate,
                                                                      termsLimit: 8, competitionLooseLimit: 500);
            var termLayer2 = new TermLayer <LinearMembershipFunction>(learningRate: lrate,
                                                                      smoothingAverageRate: smoothingAvarageRate,
                                                                      termsLimit: 12, competitionLooseLimit: 500);
            var termLayer3 = new TermLayer <LinearMembershipFunction>(learningRate: lrate,
                                                                      smoothingAverageRate: smoothingAvarageRate,
                                                                      termsLimit: 18, competitionLooseLimit: 500);
            var termLayer4 = new TermLayer <LinearMembershipFunction>(learningRate: lrate,
                                                                      smoothingAverageRate: smoothingAvarageRate,
                                                                      termsLimit: 30, competitionLooseLimit: 500);
            var fis = new InferenceLayer <LinearMembershipFunction>(
                new[] { termLayer1, termLayer2, termLayer3, termLayer4 },
                ruleset, smoothingAvarageRate);

            return(fis);
        }
Exemple #2
0
        private InferenceLayer <PiMembershipFunction> Create()
        {
            var lrate = 1e-3;
            var smoothingAvarageRate = 1e-3;

            var ruleset = new FirstLevelRuleset(2e-1);

            var termLayer = new TermLayer <PiMembershipFunction>(learningRate: lrate,
                                                                 smoothingAverageRate: smoothingAvarageRate,
                                                                 termsLimit: 200, competitionLooseLimit: 100); //TermCore.Create(0), TermCore.Create(1)
            var fis = new InferenceLayer <PiMembershipFunction>(new[] { termLayer }, ruleset, smoothingAvarageRate);

            return(fis);
        }