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

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

?? mlj.java

?? 決策樹分類中經典算法的ID3和C4.5代碼公共包!
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
package shared;
import java.lang.*;
import java.util.*;

/** This class contains methods and data members that were external to classes.
 */
public class MLJ {
    
    /** The clamping epsilon used to determine if a real value is significantly
     * different from another value.
     */    
    static public final double realEpsilon = 2.22204e-16;
    
    /** The clamping epsilon used to determine if a real value is significantly
     * different from another value.
     */    
    static public final double storedRealEpsilon= 1.1920928955078e-7;
    
    
    
    /** The clamping epsilon used to determine if a real value is significantly
     * different from another value during clamping.
     */    
    static public final double clampingEpsilon = realEpsilon * 10;
    
    /** If the given source value is lower than the lower bound, the source value is
     * changed to the lower bound value.
     * @param source The value to be clamped.
     * @param lowBound The lower bound.
     * @param additionalErrMsg Message to be displayed if clamping occurs.
     */
    static public void clamp_above(DoubleRef source, double lowBound,
    
    String additionalErrMsg) {
        clamp_above(source, lowBound, additionalErrMsg, 1);
    }
    
    
    /** If the given source value is lower than the lower bound, the source value is
     * changed to the lower bound value.
     * @param source The value to be clamped.
     * @param lowBound The lower bound.
     * @param additionalErrMsg Message to be displayed if clamping occurs.
     * @param precMultiplier The precision multiplier for real values that are close to the lower bound.
     */
    static public void clamp_above(DoubleRef source, double lowBound, String additionalErrMsg, int precMultiplier) {
        if (precMultiplier < 0) {
            Error.err(additionalErrMsg + '\n'+ "clamp_above(Real): precision multiplier ("+
            precMultiplier + ") must be non-negative-->fatal_error");
        }
        if (source.value >= lowBound) return;
        if (source.value < lowBound - clampingEpsilon * precMultiplier) {
            Error.err(additionalErrMsg + '\n'+ "clamp_above(Real): minimum value allowed ("+
            lowBound + ") exceeds variable to be clamped ("+ source + ") by more than is allowed ("+
            clampingEpsilon + ")-->fatal_error");
        }
        source.value = lowBound;
    }
    
    /** Compares two double values for equality.
     * @param lhs The left value to be compared.
     * @param rhs The right value to be compared.
     * @return TRUE if approximately equal, FALSE if significantly different.
     */
    static public boolean approx_equal(double lhs, double rhs) {
        return approx_equal(lhs,rhs,1);
    }
    
    /** Compares two double values for equality, using the given
     * precisionMultiplier to drive approximate comparisons.
     * @param lhs The left value to be compared.
     * @param rhs The right value to be compared.
     * @param precMultiplier The precision multiplier for determining if a value is signifacntly different.
     * @return TRUE if approximately equal, FALSE if significantly different.
     */
    static public boolean approx_equal(double lhs, double rhs, int precMultiplier) {
        if (Globals.DBG) MLJ.ASSERT(precMultiplier >= 0,"MLJ::approx_equal: precMultiplier < 0");
        return (Math.abs(lhs - rhs) <= clampingEpsilon * precMultiplier * Math.max(1, Math.min(Math.abs(lhs), Math.abs(rhs))));
    }
    
    
    /** Compares two arrays of double values for equality.
     * @param lhs The left array to be compared.
     * @param rhs The right array to be compared.
     * @return TRUE if approximately equal, FALSE if significantly different.
     */
    public static boolean approx_equal(double[] lhs, double[] rhs) {
        return approx_equal(lhs,rhs,1);
    }
    
    /** Compares two arrays of doubles for equality, using the given
     * precisionMultiplier to drive approximate comparisons at each element.
     * @param lhs The left array to be compared.
     * @param rhs The right array to be compared.
     * @param precisionMultiplier The precision multiplier for determining if a value is signifacntly different.
     * @return TRUE if approximately equal, FALSE if significantly different.
     */
    public static boolean approx_equal(double[] lhs, double[] rhs,
    int precisionMultiplier) {
        // FALSE if bounds differ
        if(lhs.length != rhs.length)
            return false;
        for (int x = 0; x < lhs.length; x++)
            if (!approx_equal(lhs[x], rhs[x], precisionMultiplier))
                return false;
        
        return true;
    }
    
    /** Compares two matrices of double values for equality.
     * @param lhs The left matrix to be compared.
     * @param rhs The right matrix to be compared.
     * @return TRUE if approximately equal, FALSE if significantly different.
     */
    static public boolean approx_equal(double[][] lhs, double[][] rhs) {
        return approx_equal(lhs,rhs,1);
    }
    
    /** Compares two matrices of double values for equality, using the given
     * precisionMultiplier to drive approximate comparisons at each element.
     * @param lhs The left matrix to be compared.
     * @param rhs The right matrix to be compared.
     * @param precisionMultiplier The precision multiplier for determining if a value is signifacntly different.
     * @return TRUE if approximately equal, FALSE if significantly different.
     */
    static public boolean approx_equal(double[][] lhs, double[][] rhs,
    int precisionMultiplier) {
        // FALSE if bounds differ
        if((lhs.length != rhs.length) || (lhs[0].length != rhs[0].length))
            return false;
        for (int x = 0; x < lhs.length; x++)
            for (int y = 0; y < lhs[0].length; y++)
                if (!approx_equal(lhs[x][y], rhs[x][y], precisionMultiplier))
                    return false;
        
        return true;
    }
    
    
    /** Checks if the double values are approximately equal and displays an error
     * message if they are not.
     * @param lhs The left value to be compared.
     * @param rhs The right value to be compared.
     * @param errMsg The error message to be displayed.
     */
    static public void verify_approx_equal(double lhs, double rhs, String errMsg ) {
        if (!approx_equal(lhs, rhs ))
            Error.err(errMsg + '\n'+ lhs + " versus "+ rhs + "-->fatal_error");
    }
    
    /** If the given source value is lower than the lower bound, the source value is
     * changed to the lower bound value. If the source value is above the higher bound,
     * the higher bound is substituted.
     * @param source The value to be clamped.
     * @param lowBound The lower bound.
     * @param highBound The higher bound.
     * @param additionalErrMsg An additional error message to be displayed if clamping occurs.
     */
    static public void clamp_to_range(DoubleRef source, double lowBound, double highBound, String additionalErrMsg) {
        clamp_to_range(source, lowBound, highBound, additionalErrMsg, 1);
    }
    
    /** If the given source value is lower than the lower bound, the source value is
     * changed to the lower bound value. If the source value is above the higher bound,
     * the higher bound is substituted. The precision multiplier is to determine to
     * what precision checks for significant difference are conducted.
     * @param source The value to be clamped.
     * @param lowBound The lower bound.
     * @param highBound The higher bound.
     * @param additionalErrMsg An additional error message to be displayed if clamping occurs.
     * @param precMultiplier The precision multiplier for real values that are close to the a bound.
     */
    static public void clamp_to_range(DoubleRef source, double lowBound, double highBound, String additionalErrMsg, int precMultiplier) {
        if (lowBound > highBound) {
            Error.err(additionalErrMsg + '\n'+ "clamp_to_range(Real): Lower bound of allowed range ("+
            lowBound + ") can not be greater than the upper bound of the range ("+
            highBound + ")-->fatal_error");
        }
        if (precMultiplier < 0) {
            Error.err(additionalErrMsg + '\n'+ "clamp_to_range(Real): precision multiplier ("+
            precMultiplier + ") must be non-negative-->fatal_error");
        }
        clamp_above(source, lowBound, additionalErrMsg, precMultiplier);
        clamp_below(source, highBound, additionalErrMsg, precMultiplier);
    }
    
    /** If the given source value is higher than the higher bound, the source value is
     * changed to the higher bound value.
     * @param source The value to be clamped.
     * @param highBound The higher bound.
     * @param additionalErrMsg An additional error message to be displayed if clamping occurs.
     */
    static public void clamp_below(DoubleRef source, double highBound, String additionalErrMsg) {
        clamp_below(source, highBound, additionalErrMsg, 1);
    }
    
    /** If the given source value is higher than the higher bound, the source value is
     * changed to the higher bound value.
     * @param source The value to be clamped.
     * @param highBound The higher bound.
     * @param additionalErrMsg An additional error message to be displayed if clamping occurs.
     * @param precMultiplier The precision multiplier for real values that are close to the higher bound.
     */
    static public void clamp_below(DoubleRef source, double highBound, String additionalErrMsg, int precMultiplier) {
        if (precMultiplier < 0) {
            Error.err(additionalErrMsg + '\n'+ "clamp_below(double): precision multiplier ("+
            precMultiplier + ") must be non-negative-->fatal_error");
        }
        if (source.value <= highBound) return;
        if (source.value > highBound + clampingEpsilon * precMultiplier) {
            Error.err(additionalErrMsg + '\n'+ "clamp_below(double): variable to be clamped ("+
            source + ") exceeds maximum value allowed ("+ highBound + ") by more than allowed ("+
            clampingEpsilon + ")-->fatal_error");
        }
        source.value = highBound;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久品道一品道久久精品| 7777精品伊人久久久大香线蕉完整版 | 日韩精品欧美精品| 亚洲综合色成人| 亚洲综合一区二区精品导航| 亚洲欧美日韩人成在线播放| 一区二区三区四区蜜桃| 亚洲精品日产精品乱码不卡| 亚洲一区二区三区国产| 亚洲成a人v欧美综合天堂 | 日韩欧美在线观看一区二区三区| 91精品久久久久久久91蜜桃| 久久综合一区二区| 国产精品你懂的| 亚洲与欧洲av电影| 日本最新不卡在线| 国产一区二区看久久| 99精品在线观看视频| 欧美欧美欧美欧美| 久久免费精品国产久精品久久久久 | 日韩三级免费观看| 亚洲国产精品99久久久久久久久 | 在线区一区二视频| 欧美一级xxx| 国产欧美一区二区在线观看| 中文字幕日韩av资源站| 亚洲成人av一区二区三区| 久久精品免费观看| 91丨porny丨首页| 欧美人妖巨大在线| 国产精品美女久久久久aⅴ国产馆 国产精品美女久久久久av爽李琼 国产精品美女久久久久高潮 | 久久久综合精品| 亚洲欧美日韩人成在线播放| 日韩精品一二三区| 成人福利在线看| 欧美久久高跟鞋激| 中文字幕在线一区二区三区| 奇米综合一区二区三区精品视频| 国产精品一区二区久久不卡| 欧美性受xxxx| 国产精品久久久久久久久晋中| 日本视频中文字幕一区二区三区| 不卡影院免费观看| 欧美zozo另类异族| 日欧美一区二区| 日本韩国欧美三级| 国产精品入口麻豆原神| 激情文学综合丁香| 日韩一区二区免费视频| 亚洲精选一二三| 成人开心网精品视频| 欧美不卡一区二区三区四区| 亚洲va天堂va国产va久| 一本久久a久久精品亚洲| 久久久久久99精品| 狠狠色2019综合网| 欧美精品在线观看播放| 一区二区三国产精华液| 成人国产免费视频| 亚洲国产高清aⅴ视频| 国产精品正在播放| 精品毛片乱码1区2区3区| 蜜臀av一级做a爰片久久| 欧美日韩在线综合| 亚洲一区二区三区四区在线 | www国产精品av| 日本欧美一区二区| 91麻豆精品国产91久久久资源速度 | 丝袜美腿高跟呻吟高潮一区| 99久久亚洲一区二区三区青草| 中文字幕第一区| 成人夜色视频网站在线观看| 国产三级久久久| 成人午夜视频在线| 综合分类小说区另类春色亚洲小说欧美| 国产成人免费9x9x人网站视频| 久久久久国产精品麻豆| 极品尤物av久久免费看| 久久精品亚洲精品国产欧美kt∨| 狠狠色综合日日| 久久久久久免费| 成人av在线看| 夜色激情一区二区| 666欧美在线视频| 久久97超碰国产精品超碰| 精品国产乱码91久久久久久网站| 国产精品羞羞答答xxdd| 国产精品网曝门| 欧洲生活片亚洲生活在线观看| 一区二区三区在线看| 欧美日韩中字一区| 日本午夜一本久久久综合| 久久综合久久综合久久| 顶级嫩模精品视频在线看| 亚洲婷婷综合久久一本伊一区| 欧美三级乱人伦电影| 久久成人久久爱| 国产精品久久久久影视| 欧美三级日韩三级国产三级| 久久99国产精品尤物| 国产精品乱码一区二三区小蝌蚪| 91网站最新网址| 欧美bbbbb| 中文av一区二区| 6080国产精品一区二区| 国产成人在线看| 亚洲一区二区视频在线| 久久久国产午夜精品 | 久久99精品国产.久久久久| 国产精品久久看| 欧美一区二区福利在线| 成人动漫一区二区| 日本不卡的三区四区五区| 国产精品久久久久久久久图文区| 欧美私人免费视频| 国产一区二区三区四区五区入口 | 日韩欧美综合在线| 成人在线视频首页| 亚洲国产日韩精品| 国产精品成人一区二区三区夜夜夜| 欧美丰满少妇xxxbbb| 色综合天天综合网天天狠天天| 国产一区欧美日韩| 亚洲va国产天堂va久久en| 国产日韩精品一区二区浪潮av | 国产女人水真多18毛片18精品视频| 欧美综合久久久| 成人开心网精品视频| 精品中文av资源站在线观看| 亚洲一区二区偷拍精品| 成人欧美一区二区三区白人| 欧美精品一区二区三区高清aⅴ| 欧美色区777第一页| 成人动漫视频在线| 成人一区二区视频| 韩国一区二区视频| 另类小说色综合网站| 亚洲国产精品久久人人爱蜜臀| 亚洲人成网站精品片在线观看| 国产区在线观看成人精品| 日韩你懂的在线播放| 欧美二区三区的天堂| 欧美三级韩国三级日本一级| 91久久精品网| 91无套直看片红桃| 一本大道av一区二区在线播放 | 日韩激情av在线| 午夜a成v人精品| 午夜日韩在线电影| 亚洲亚洲人成综合网络| 亚洲一区二区三区爽爽爽爽爽| 亚洲理论在线观看| 亚洲日本一区二区三区| 一区二区三区在线免费视频| 亚洲精选在线视频| 香蕉久久夜色精品国产使用方法 | av在线不卡电影| 99久久国产综合精品女不卡| 99久久精品久久久久久清纯| 北条麻妃国产九九精品视频| proumb性欧美在线观看| 91视频免费看| 欧美视频第二页| 欧美一区二区精品| 欧美xxxxx牲另类人与| 国产欧美一区二区三区网站| 国产精品超碰97尤物18| 亚洲一区欧美一区| 另类综合日韩欧美亚洲| 韩国视频一区二区| 成人爱爱电影网址| 欧美探花视频资源| 久久综合av免费| 中文字幕在线不卡一区| 午夜av一区二区| 国产精品一区二区你懂的| 一道本成人在线| 精品久久久久99| 亚洲狼人国产精品| 久久99国产精品免费| 色综合久久综合网欧美综合网| 欧美一区二区福利在线| 欧美国产欧美综合| 午夜影院久久久| 国产精品影音先锋| 在线精品视频免费播放| 欧美大片顶级少妇| 亚洲精品日韩一| 国产成人在线观看| 欧美美女一区二区| 中文字幕在线不卡| 精品一区二区三区在线播放视频| 91网站视频在线观看| 日韩欧美激情在线| 亚洲久草在线视频| 岛国一区二区在线观看| 91精品国产91久久久久久最新毛片 | 国产麻豆91精品| 欧美日韩国产免费一区二区 | 亚洲成av人片一区二区梦乃|