Exemplo n.º 1
0
        public override void Work()
        {
            GIBNormal      = fuzzy_system.getGIBNormal();
            GIBSumStraigth = fuzzy_system.getGIBSumStrait();
            GIBSumReverce  = fuzzy_system.getGIBSumReverse();

            GICNormal     = fuzzy_system.getGICNormal();
            GICSumReverce = fuzzy_system.getGICSumReverce();
            GICSumStraigh = fuzzy_system.getGICSumStraigth();

            GISNormal      = fuzzy_system.getGISNormal();
            GISSumReverce  = fuzzy_system.getGISSumReverce();
            GISSumStraigth = fuzzy_system.getGISSumStraigt();

            LindisNormal     = fuzzy_system.getLindisNormal();
            LindisSumStraigh = fuzzy_system.getLindisSumStraight();
            LindisSumReverce = fuzzy_system.getLindisSumReverse();

            NormalIndex       = fuzzy_system.getNormalIndex();
            SumReverseIndex   = fuzzy_system.getIndexSumReverse();
            SumsStraigthIndex = fuzzy_system.getIndexSumStraigt();



            SAFSUFSWriter.saveToUFS(fuzzy_system, Source);
        }
Exemplo n.º 2
0
 protected static void writeAboutEstimates(XmlWriter writer, SAFuzzySystem Approximate)
 {
     writer.WriteStartElement("Estimates");
     if (Approximate.TestSamplesSet != null)
     {
         writer.WriteAttributeString("Count", XmlConvert.ToString(22));
         writer.WriteStartElement("Estimate");
         writer.WriteAttributeString("Table", Approximate.LearnSamplesSet.FileName);
         writer.WriteAttributeString("Type", "RMSE");
         writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.approxLearnSamples(Approximate.RulesDatabaseSet[0])));
         writer.WriteEndElement();
         writer.WriteStartElement("Estimate");
         writer.WriteAttributeString("Table", Approximate.LearnSamplesSet.FileName);
         writer.WriteAttributeString("Type", "MSE");
         writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.RMSEtoMSEforLearn(Approximate.approxLearnSamples(Approximate.RulesDatabaseSet[0]))));
         writer.WriteEndElement();
         writer.WriteStartElement("Estimate");
         writer.WriteAttributeString("Table", Approximate.TestSamplesSet.FileName);
         writer.WriteAttributeString("Type", "RMSE");
         writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.approxTestSamples(Approximate.RulesDatabaseSet[0])));
         writer.WriteEndElement();
         writer.WriteStartElement("Estimate");
         writer.WriteAttributeString("Table", Approximate.TestSamplesSet.FileName);
         writer.WriteAttributeString("Type", "MSE");
         writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.RMSEtoMSEforTest(Approximate.approxTestSamples(Approximate.RulesDatabaseSet[0]))));
         writer.WriteEndElement();
     }
     else
     {
         writer.WriteAttributeString("Count", XmlConvert.ToString(20));
         writer.WriteStartElement("Estimate");
         writer.WriteAttributeString("Table", Approximate.LearnSamplesSet.FileName);
         writer.WriteAttributeString("Type", "RMSE");
         writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.approxLearnSamples(Approximate.RulesDatabaseSet[0])));
         writer.WriteEndElement();
         writer.WriteStartElement("Estimate");
         writer.WriteAttributeString("Table", Approximate.LearnSamplesSet.FileName);
         writer.WriteAttributeString("Type", "MSE");
         writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.RMSEtoMSEforLearn(Approximate.approxLearnSamples(Approximate.RulesDatabaseSet[0]))));
         writer.WriteEndElement();
     }
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GIBNormal");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGIBNormal()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GIBSumStraigh");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGIBSumStrait()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GIBSumReverse");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGIBSumReverse()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GICNormal");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGICNormal()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GICSumStraigh");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGICSumStraigth()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GICSumReverse");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGICSumReverce()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GISNormal");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGISNormal()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GISSumStraigh");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGISSumStraigt()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "GISSumReverce");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getGISSumReverce()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "LindisNormal");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getLindisNormal()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "LindisSumStraigh");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getLindisSumStraight()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "LindisSumReverse");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getLindisSumReverse()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "NormalIndex");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getNormalIndex()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "RealIndex");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getIndexReal()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "SumStraigthIndex");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getIndexSumStraigt()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "SumReverseIndex");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getIndexSumReverse()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "ComplexitIt");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getComplexit()));
     writer.WriteEndElement();
     writer.WriteStartElement("Estimate");
     writer.WriteAttributeString("Type", "CountRules");
     writer.WriteAttributeString("Value", XmlConvert.ToString(Approximate.getRulesCount()));
     writer.WriteEndElement();
     writer.WriteEndElement();
 }