亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? id3inducer.java

?? 經典的ID3
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
               if (mutualInfoAboveMean || !foundScoreAboveMean) {
//                  MLJ.ASSERT(meanMutualInfo != Globals.UNDEFINED_REAL);
                  logOptions.LOG(3, ", and that "+split.score()+" > "+meanMutualInfo+'\n');
                  double score = split.score();
                  logOptions.LOG(3,"Testing attribute "+attrNum+" ("+schema.attr_name(attrNum)+"): "+'\n');
//                  logOptions.LOG(3,split);
//                  logOptions.LOG(3,"Comparing score ("+score+") against max score + eps ("+
//                     (maxScore+MLJ.realEpsilon())+")"+'\n');
                  if (score > maxScore + MLJ.realEpsilon ||
                     (!foundScoreAboveMean && mutualInfoAboveMean)) {
                     logOptions.LOG(2,"Chose attribute "+attrNum+'\n');
                     maxScore = score;
                     bestSplit[0] = split;
                     logOptions.LOG(3,"max score becomes "+maxScore+'\n');
                  }
                  if (mutualInfoAboveMean)
                     foundScoreAboveMean = true;
               } else{
                  logOptions.LOG(3,"...not above mean"+'\n');
               }
            }
         }
      }
   }

   /** Checks if all attributes are multi-valued. An attribute is multivalued if
    * an instance can have more than one value at one time. If the attribute
    * contains values that are neither real or nominal, an abort message is issued.
    * @return False if the values are real numbers or if the nominal values are
    * not multivalued. Otherwise True is returned.
    */
   public boolean all_attributes_multi_val() 
   {
      boolean multiVal = true;
      Schema schema = TS.get_schema();
      for (int attrNum = 0; attrNum < schema.num_attr() && multiVal; attrNum++){
         if (schema.attr_info(attrNum).can_cast_to_real())
            multiVal = false;
         else if (schema.attr_info(attrNum).can_cast_to_nominal())
            multiVal = multi_val_attribute(attrNum);
               else
                  MLJ.Abort();
      }
      return multiVal;
   }
   /** Compute the split information for a given attribute.
    * @param attrNum The index number of this attribute column.
    * @param split The attribute to be split on.
    */
   public void split_info(int attrNum, SplitAttr split)
   {
      split_info(attrNum, split, null);
   }

   /** Compute the split information for a given attribute.
    * @param attrNum     The index number of this attribute column.
    * @param split       The attribute to be split on.
    * @param realColumns The columns of values specified for each attribute over
    * all instances in a data set.
    */
   public void split_info(int attrNum, SplitAttr split,
		   RealAndLabelColumn[] realColumns) 
   {
      Schema schema = TS.get_schema();

      if (attrNum < 0 || attrNum > schema.num_attr())
         Error.fatalErr("ID3Inducer::split_info: attrNum " + attrNum +
            " not in range 0 to " + schema.num_attr());
   
      logOptions.LOG(2,"Testing attribute "+attrNum+" ("+TS.get_schema().attr_name(attrNum)+"): ");

   // split needs to know if the Minimum Description Length Adjustment
   //   for continuous attributes needs to be applied.
      split.set_penalize_by_mdl(get_cont_mdl_adjust());
      double minSplit = Entropy.min_split(instance_list(),
			     get_lower_bound_min_split_weight(),
			     get_upper_bound_min_split_weight(),
			     get_min_split_weight_percent());
      double nominalMinSplit = minSplit;
      if (get_nominal_lbound_only()) {
         nominalMinSplit = get_lower_bound_min_split_weight();
         if (nominalMinSplit < 1)
            Error.fatalErr("split_info:  lowerBoundMinSplit (" +
               nominalMinSplit+") must be at least one");
      }
      logOptions.LOG(4,"Min split: "+(int)minSplit+", nominal min split: "+(int)nominalMinSplit+'\n');

   // If the attribute is nominal and has more than one value, then use
   //   mutual_info or gain_ratio to determine the information gained by
   //   splitting on it.
      if (schema.attr_info(attrNum).can_cast_to_nominal()) {
         split.set_split_score_criterion(get_split_score_criterion());
         if (SplitAttr.ok_to_split(attrNum, TS.counters(), nominalMinSplit)) {
            split.make_nominal_split(instance_list(), attrNum);
            logOptions.LOG(2,"Criterion score for attribute "+attrNum+" is "+split.score()+'\n');
	 MLJ.ASSERT(split.score() >= 0, "ID3Inducer::split_info(): split.score() >= 0");
         }
      }
   // Otherwise the attribute should be real and real_mutual_info is used
   //   to determine the threshold which gives the maximum information
   //   gain when split on.
      else if (schema.attr_info(attrNum).can_cast_to_real()) {
      // Find the best threshold (in find_best_threshold(), invoked through
      //   make_real_split()) based on the default split criterion; then
      //   set the criterion back.
      // @@ This will be an option for reals.
         if (realColumns == null)
            Error.fatalErr("ID3Inducer::split_info: can't split on real attribute "+
               schema.attr_name(attrNum)+" -- realColumns is null");
         RealAndLabelColumn column = realColumns[attrNum];
         if (column == null)
            Error.fatalErr("ID3Inducer::split_info: can't split on real attribute "+
               schema.attr_name(attrNum)+" -- the given column is null");
         column.sort();

         split.set_split_score_criterion(SplitScore.defaultSplitScoreCriterion);
         split.set_penalize_by_mdl(false);
         split.make_real_split(column, attrNum, minSplit,
            get_smooth_inst(), get_smooth_factor());
         split.set_split_score_criterion(get_split_score_criterion());
         split.set_penalize_by_mdl(get_cont_mdl_adjust());
         if (split.exist_split()) {
            logOptions.LOG(2,"Threshold: "+split.threshold()+", criterion score: "+
               split.score()+", entropy: "+split.get_entropy()+'\n');
            MLJ.ASSERT(split.score() >= 0, "ID3Inducer::split_info(): split.score() >= 0");
         }
      } else
         MLJ.Abort();
      
      if (split.split_type() == SplitAttr.noReasonableSplit)
      	logOptions.LOG(2,"No reasonable split"+'\n');
   }

//   public void set_unknown_edges(){ }

//   public void display_struct(){ }

//Additions by JL

//   private NO_DEFAULT_OPS(ID3Inducer);

   /** Create an Inducer for recursive calls. Since TDDTInducer is an abstract
    * class, it can't do the recursive call.
    * @param descr   The description of the new subinducer.
    * @param aCgraph A previously defined Cgraph for the inducer.
    * @return The new sub-ID3Inducer created.
    */
   public TDDTInducer create_subinducer(String descr, CGraph aCgraph) 
   {
      ID3Inducer inducer = new ID3Inducer(descr, aCgraph);
      inducer.copy_options(this);
      inducer.set_level(get_level() + 1);
      return inducer;
   }

   /** Build categorizer for the given attribute. The specified SplitAttr is
    * assumed to be valid.
    * @param split    The attribute to be split on.
    * @param catNames The category names that an instance may be categorized
    * under.
    * @return The NodeCategorizer containing a categorizer that splits on this
    * attribute.
    */
   public NodeCategorizer split_to_cat(SplitAttr split,
					 LinkedList catNames) 
   {
      int attrNum = split.get_attr_num();
      Schema schema = TS.get_schema();

//   MLJ.ASSERT(split.split_type() != SplitAttr::noReasonableSplit);
//   MLJ.ASSERT(attrNum >= 0);
//   MLJ.ASSERT(split.score() >= 0);
   
   // Else, build the categorizer
      String attrName = schema.attr_info(attrNum).name();
      if (get_debug()) {
         attrName = attrName+" (#=" + TS.num_instances()+
            "\\nENT="+ split.get_entropy()+
            "\\nMI=" + split.get_mutual_info(false, false)+
            "\\nGAIN=" + split.get_gain_ratio(false);
         if (split.get_penalize_by_mdl())
            attrName =attrName+"\\nMDL penalty=" + split.penalty();
         attrName =attrName+"\\nSCORE=" + split.score() + ")";
      }

      if (schema.attr_info(attrNum).can_cast_to_nominal()) {
//         MLJ.ASSERT(split.split_type() == SplitAttr::nominalSplit);
         NominalAttrInfo nai = schema.attr_info(attrNum).cast_to_nominal();
         int size = nai.num_values() + 1; // +1 for unknown
//         catNames = new String[size];//(Globals.UNKNOWN_CATEGORY_VAL, size);
         catNames.add(Globals.UNKNOWN_CATEGORY_VAL,"?");
         int cat = Globals.FIRST_CATEGORY_VAL;
         for (int i = 1; i < size; i++, cat++)
            catNames.add(cat,nai.get_value(i));

//UNKNOWN_NOMINAL_VAL is now 0 instead of -1. As a result, the 
//original input value for get_value would have been out of bounds 
//for the number of values. - JL
//            catNames.add(cat,nai.get_value(i + Globals.UNKNOWN_NOMINAL_VAL));
      
         return new AttrCategorizer(schema, attrNum, attrName);
      }
      else if (schema.attr_info(attrNum).can_cast_to_real()) {
         if (split.split_type() == SplitAttr.realThresholdSplit) {
            logOptions.LOG(5, split.threshold()+""+'\n');	 
            ThresholdCategorizer cat = new
            ThresholdCategorizer(schema, attrNum, split.threshold(),
               attrName);
		String[] categories = cat.real_edge_strings();
            for(int z = 0; z < categories.length; z++)
			catNames.add(z,categories[z]);
            return cat;
         } else {
            Error.fatalErr("ID3Inducer::split_to_cat: bad split type for "+
               "continuous attribute "+attrNum);
            return null;
         }
      } else {
         Error.fatalErr("ID3Inducer::split_to_cat: unrecognized attribute type"+
            " for attribute "+attrNum);
         return null;
      }
   }

   /** Returns the reference to the copy of ID3Inducer with the same settings.
    * @return A reference to an ID3Inducer.
    */
   public Inducer copy() 
   {
      Inducer ind = new ID3Inducer(this);
      return ind;
   }

   /** Returns the class id of this of this inducer.
    * @deprecated This method should be replaced with Java's instanceof operator.
    * @return Integer assigned to this inducer.
    */
   public int class_id(){ return ID3_INDUCER; }

}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
8x8x8国产精品| 久久国产麻豆精品| 肉色丝袜一区二区| 精品综合久久久久久8888| 国产一区不卡精品| 99久久精品99国产精品| 欧美一区二区三区在线看| 国产午夜一区二区三区| 欧美亚洲综合网| 99视频一区二区| 在线不卡欧美精品一区二区三区| 2024国产精品| 亚洲天堂免费在线观看视频| 日韩av中文在线观看| 国产成人欧美日韩在线电影 | 久久久久久久综合日本| 亚洲欧洲精品一区二区三区| 日本美女一区二区三区视频| 精品一区二区三区日韩| 欧洲人成人精品| 欧美一个色资源| 一区二区三区毛片| 国产麻豆欧美日韩一区| 91在线丨porny丨国产| 正在播放一区二区| 国产精品欧美极品| 一区二区在线观看视频在线观看| 精久久久久久久久久久| 欧美性受极品xxxx喷水| 国产色产综合产在线视频| 丝袜亚洲精品中文字幕一区| 99视频精品免费视频| 久久综合色一综合色88| 五月婷婷综合激情| 91视视频在线观看入口直接观看www| 日韩天堂在线观看| 亚洲图片自拍偷拍| 97aⅴ精品视频一二三区| 久久免费午夜影院| 免费观看日韩av| 欧美午夜精品久久久久久超碰 | 国产传媒欧美日韩成人| 欧美一二三区在线| 亚洲大片免费看| 97国产一区二区| 国产精品久久久久久久久久久免费看| 理论电影国产精品| 91精品黄色片免费大全| 亚洲一区二三区| 91香蕉视频黄| 亚洲人成网站精品片在线观看| 污片在线观看一区二区| 蜜臀av亚洲一区中文字幕| 色综合久久久久综合99| 亚洲欧美在线视频观看| 国产盗摄一区二区| 久久久www免费人成精品| 日韩在线播放一区二区| 欧美综合久久久| 亚洲乱码国产乱码精品精小说 | 亚洲天堂精品在线观看| 成人高清在线视频| 欧美高清一级片在线观看| 国产伦理精品不卡| 2023国产精品| 国产精品一级黄| 国产午夜亚洲精品理论片色戒| 激情五月激情综合网| 精品国产一区二区三区忘忧草| 日本不卡视频在线| 欧美一二三四区在线| 美女视频一区二区| 日韩午夜在线观看视频| 久草中文综合在线| 久久久噜噜噜久久人人看| 国产一区二区三区黄视频| 精品久久久久久无| 国产成人综合精品三级| 国产精品女上位| 色综合久久天天| 亚洲第一在线综合网站| 欧美久久久影院| 麻豆91精品91久久久的内涵| 日韩午夜激情免费电影| 国产一区二区视频在线| 国产清纯在线一区二区www| 成人中文字幕合集| 亚洲欧美色图小说| 欧美日韩在线播放三区| 蜜桃久久久久久| 久久久综合九色合综国产精品| 国产精品亚洲午夜一区二区三区| 国产欧美视频在线观看| 91色在线porny| 亚洲午夜成aⅴ人片| 欧美一级一级性生活免费录像| 精品一区二区三区视频| 中文字幕av在线一区二区三区| 色综合天天做天天爱| 亚洲国产aⅴ成人精品无吗| 欧美一区二区三区不卡| 激情成人午夜视频| 国产精品福利av| 欧美日韩国产色站一区二区三区| 久久99久国产精品黄毛片色诱| 久久久久国产精品免费免费搜索| 不卡在线视频中文字幕| 亚洲不卡av一区二区三区| 精品国产99国产精品| 白白色 亚洲乱淫| 午夜av电影一区| 日本一区二区三区在线观看| 欧美四级电影网| 18成人在线观看| av在线播放成人| 午夜精品福利在线| 国产欧美日韩精品a在线观看| 99在线视频精品| 美女视频免费一区| 1024成人网| 精品美女一区二区| 色偷偷久久人人79超碰人人澡| 免费av成人在线| 亚洲精品v日韩精品| 日韩免费成人网| 在线亚洲免费视频| 国产一区二区三区黄视频 | 欧美日韩中文国产| 黄网站免费久久| 亚洲国产综合91精品麻豆 | 91色porny蝌蚪| 韩国欧美一区二区| 亚洲第一成人在线| 国产日韩欧美综合在线| 在线不卡中文字幕| 色综合色狠狠天天综合色| 国内不卡的二区三区中文字幕| 亚洲自拍都市欧美小说| 欧美激情在线观看视频免费| 91精品一区二区三区在线观看| 91婷婷韩国欧美一区二区| 国产在线精品不卡| 午夜精品在线视频一区| 国产精品久久久久久久午夜片 | 国产成人a级片| 日韩精品五月天| 亚洲国产精品影院| 亚洲欧洲日产国产综合网| 久久久蜜桃精品| 精品国产乱码久久久久久夜甘婷婷| 欧美三片在线视频观看 | 日一区二区三区| 亚洲自拍偷拍网站| 成人欧美一区二区三区视频网页| 精品国产自在久精品国产| 91麻豆精品国产91久久久使用方法 | 欧美视频在线播放| av在线一区二区| 成人午夜av影视| 国产99精品国产| 国产毛片精品一区| 麻豆一区二区三区| 日本少妇一区二区| 三级久久三级久久| 婷婷综合五月天| 香港成人在线视频| 亚洲一区二区三区在线看| 一本色道a无线码一区v| 国产乱国产乱300精品| 美女脱光内衣内裤视频久久网站 | 欧美视频一区在线| 欧美亚洲一区二区三区四区| 91色porny在线视频| 99国产麻豆精品| 99久久99久久久精品齐齐| 成人av网站在线| gogogo免费视频观看亚洲一| 国产成人av电影在线| 国产福利91精品| 国产成人午夜视频| 国产精品77777| 成人视屏免费看| 9人人澡人人爽人人精品| 成a人片国产精品| 91免费在线看| 在线看国产一区二区| 欧美性色综合网| 欧美日韩久久久久久| 欧日韩精品视频| 欧美日韩国产大片| 日韩欧美电影一区| 欧美大度的电影原声| 精品免费99久久| 日本一区二区三区四区在线视频| 欧美国产综合色视频| 国产精品久久久久久久第一福利| 国产精品国产三级国产普通话三级| 日韩美女视频19| 午夜影视日本亚洲欧洲精品| 午夜不卡av在线|