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

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

?? hooks.c

?? c5.0算法源代碼
?? C
?? 第 1 頁 / 共 5 頁
字號:
/*************************************************************************//*									 *//*	Source code for use with See5/C5.0 Release 1.19			 *//*	-----------------------------------------------			 *//*		      Copyright RuleQuest Research 2003			 *//*									 *//*	This code is provided "as is" without warranty of any kind,	 *//*	either express or implied.  All use is at your own risk.	 *//*									 *//*************************************************************************/#define	MAXLINEBUFFER	10000char	LineBuffer[MAXLINEBUFFER], *LBp=LineBuffer;/*************************************************************************//*									 *//*	Read a name from file f into string s, setting Delimiter.	 *//*									 *//*	- Embedded periods are permitted, but periods followed by space	 *//*	  characters act as delimiters.					 *//*	- Embedded spaces are permitted, but multiple spaces are	 *//*	  replaced by a single space.					 *//*	- Any character can be escaped by '\'.				 *//*	- The remainder of a line following '|' is ignored.		 *//*									 *//*************************************************************************/Boolean ReadName(FILE *f, String s, int n, char ColonOpt)/*      --------  */{    register char *Sp=s;    register int  c;    char	  Msg[2];    /*  Skip to first non-space character  */    while ( (c = InChar(f)) == '|' || Space(c) )    {	if ( c == '|' ) SkipComment;    }    /*  Return false if no names to read  */    if ( c == EOF )    {	Delimiter = EOF;	return false;    }    /*  Read in characters up to the next delimiter  */    while ( c != ColonOpt && c != ',' && c != '\n' && c != '|' && c != EOF )    {	if ( --n <= 0 )	{	    if ( Of ) Error(LONGNAME, "", "");	}	if ( c == '.' )	{	    if ( (c = InChar(f)) == '|' || Space(c) || c == EOF ) break;	    *Sp++ = '.';	    continue;	}	if ( c == '\\' )	{	    c = InChar(f);	}	if ( Space(c) )	{	    *Sp++ = ' ';	    while ( ( c = InChar(f) ) == ' ' || c == '\t' )		;	}	else	{	    *Sp++ = c;	    c = InChar(f);	}    }    if ( c == '|' ) SkipComment;    Delimiter = c;    /*  Special case for ':='  */    if ( Delimiter == ':' )    {	if ( *LBp == '=' )	{	    Delimiter = '=';	    LBp++;	}    }    /*  Strip trailing spaces  */    while ( Sp > s && Space(*(Sp-1)) ) Sp--;    if ( Sp == s )    {	Msg[0] = ( Space(c) ? '.' : c );	Msg[1] = '\00';	Error(MISSNAME, Fn, Msg);    }    *Sp++ = '\0';    return true;}/*************************************************************************//*									 *//*	Read names of classes, attributes and legal attribute values.	 *//*	On completion, names are stored in:				 *//*	  ClassName	-	class names				 *//*	  AttName	-	attribute names				 *//*	  AttValName	-	attribute value names			 *//*	with:								 *//*	  MaxAttVal	-	number of values for each attribute	 *//*									 *//*	Other global variables set are:					 *//*	  MaxAtt	-	maximum attribute number		 *//*	  MaxClass	-	maximum class number			 *//*									 *//*	Note:  until the number of attributes is known, the name	 *//*	       information is assembled in local arrays			 *//*									 *//*************************************************************************/void GetNames(FILE *Nf)/*   --------  */{    char	Buffer[1000]="";    int		AttCeiling=100, ClassCeiling=100;    Attribute	Att;    ErrMsgs = AttExIn = 0;    LineNo  = 0;    LBp     = LineBuffer;    *LBp    = 0;    /*  Get class names from names file  */    ClassName = AllocZero(ClassCeiling, String);    MaxClass = ClassAtt = LabelAtt = 0;    do    {	ReadName(Nf, Buffer, 1000, ':');	if ( ++MaxClass >= ClassCeiling)	{	    ClassCeiling += 100;	    Realloc(ClassName, ClassCeiling, String);	}	ClassName[MaxClass] = CopyString(Buffer);    }    while ( Delimiter == ',' );    /*  Get attribute and attribute value names from names file  */    AttName = AllocZero(AttCeiling, String);    MaxAttVal = AllocZero(AttCeiling, DiscrValue);    AttValName = AllocZero(AttCeiling, String *);    SpecialStatus = AllocZero(AttCeiling, char);    AttDef = AllocZero(AttCeiling, Definition);    MaxAtt = 0;    while ( ReadName(Nf, Buffer, 1000, ':') )    {	if ( Delimiter != ':' && Delimiter != '=' )	{	    Error(BADATTNAME, Buffer, "");	}	/*  Check for include/exclude instruction  */	if ( ( *Buffer == 'a' || *Buffer == 'A' ) &&	     ! memcmp(Buffer+1, "ttributes ", 10) &&	     ! memcmp(Buffer+strlen(Buffer)-6, "cluded", 6) )	{	    AttExIn = ( ! memcmp(Buffer+strlen(Buffer)-8, "in", 2) ? 1 : -1 );	    if ( AttExIn == 1 )	    {		ForEach(Att, 1, MaxAtt)		{		    SpecialStatus[Att] |= SKIP;		}	    }	    while ( ReadName(Nf, Buffer, 1000, ':') )	    {		Att = Which(Buffer, AttName, 1, MaxAtt);		if ( ! Att )		{		    Error(UNKNOWNATT, Buffer, Nil);		}		else		if ( AttExIn == 1 )		{		    SpecialStatus[Att] -= SKIP;		}		else		{		    SpecialStatus[Att] |= SKIP;		}	    }	    break;	}	if ( Which(Buffer, AttName, 1, MaxAtt) > 0 )	{	    Error(DUPATTNAME, Buffer, Nil);	}	if ( ++MaxAtt >= AttCeiling )	{	    AttCeiling += 100;	    Realloc(AttName, AttCeiling, String);	    Realloc(MaxAttVal, AttCeiling, DiscrValue);	    Realloc(AttValName, AttCeiling, String *);	    Realloc(SpecialStatus, AttCeiling, char);	    Realloc(AttDef, AttCeiling, Definition);	}	AttName[MaxAtt] = CopyString(Buffer);	SpecialStatus[MaxAtt] = Nil;	AttDef[MaxAtt] = Nil;	MaxAttVal[MaxAtt] = 0;	if ( Delimiter == '=' )	{	    if ( MaxClass == 1 && ! strcmp(ClassName[1], AttName[MaxAtt]) )	    {		Error(BADDEF3, Nil, Nil);	    }	    ImplicitAtt(Nf);	}	else	{	    ExplicitAtt(Nf);	}    }    /*  Check whether class is one of the attributes  */    if ( MaxClass == 1 )    {	ClassAtt = Which(ClassName[1], AttName, 1, MaxAtt);	/*  Make sure not excluding class attribute  */	if ( Skip(ClassAtt) ) SpecialStatus[ClassAtt] -= SKIP;	/*  Class attribute must be present and must be discrete  */	if ( ClassAtt <= 0 )	{	    Error(NOTARGET, ClassName[1], "");	}	else	if ( Continuous(ClassAtt) ||	     StatBit(ClassAtt, DISCRETE|EXCLUDE) )	{	    Error(BADTARGET, ClassName[1], "");	}	Free(ClassName[1]);	Free(ClassName);	MaxClass  = MaxAttVal[ClassAtt];	ClassName = AttValName[ClassAtt];    }    ClassName[0] = CopyString("?");    fclose(Nf);    if ( ErrMsgs > 0 ) Goodbye(1);}/*************************************************************************//*									 *//*	Continuous or discrete attribute				 *//*									 *//*************************************************************************/void ExplicitAtt(FILE *Nf)/*   -----------  */{    char	Buffer[1000]="", *p;    DiscrValue	v;    int		ValCeiling=100, BaseYear;    time_t	clock;    /*  Read attribute type or first discrete value  */    if ( ! ( ReadName(Nf, Buffer, 1000, ':') ) )    {	Error(EOFINATT, AttName[MaxAtt], "");    }    MaxAttVal[MaxAtt] = 0;    if ( Delimiter != ',' )    {	/*  Typed attribute  */	if ( ! strcmp(Buffer, "continuous") )	{	}	else	if ( ! strcmp(Buffer, "timestamp") )	{	    SpecialStatus[MaxAtt] = TSTMPVAL;	    /*  Set the base date if not done already  */	    if ( ! TSBase )	    {		clock = time(0);		BaseYear = gmtime(&clock)->tm_year + 1900;		SetTSBase(BaseYear);	    }	}	else	if ( ! strcmp(Buffer, "date") )	{	    SpecialStatus[MaxAtt] = DATEVAL;	}	else	if ( ! strcmp(Buffer, "time") )	{	    SpecialStatus[MaxAtt] = STIMEVAL;	}	else	if ( ! memcmp(Buffer, "discrete", 8) )	{	    SpecialStatus[MaxAtt] = DISCRETE;	    /*  Read max values and reserve space  */	    v = atoi(&Buffer[8]);	    if ( v < 2 )	    {		Error(BADDISCRETE, AttName[MaxAtt], "");	    }	    AttValName[MaxAtt] = Alloc(v+3, String);	    AttValName[MaxAtt][0] = (char *) (int) v+1;	    AttValName[MaxAtt][(MaxAttVal[MaxAtt]=1)] = CopyString("N/A");	}	else	if ( ! strcmp(Buffer, "ignore") )	{	    SpecialStatus[MaxAtt] = EXCLUDE;	}	else	if ( ! strcmp(Buffer, "label") )	{	    LabelAtt = MaxAtt;	    SpecialStatus[MaxAtt] = EXCLUDE;	}	else	{	    /*  Cannot have only one discrete value for an attribute  */	    Error(SINGLEATTVAL, AttName[MaxAtt], Buffer);	}    }    else    {	/*  Discrete attribute with explicit values  */	AttValName[MaxAtt] = AllocZero(ValCeiling, String);	/*  Add "N/A" unless this attribute is the class  */	if ( MaxClass > 1 || strcmp(ClassName[1], AttName[MaxAtt]) )	{	    AttValName[MaxAtt][(MaxAttVal[MaxAtt]=1)] = CopyString("N/A");	}	else	{	    MaxAttVal[MaxAtt] = 0;	}	p = Buffer;	/*  Special check for ordered attribute  */	if ( ! memcmp(Buffer, "[ordered]", 9) )	{	    SpecialStatus[MaxAtt] = ORDERED;	    for ( p = Buffer+9 ; Space(*p) ; p++ )		;	}	/*  Record first real explicit value  */	AttValName[MaxAtt][++MaxAttVal[MaxAtt]] = CopyString(p);	/*  Record remaining values  */	do	{	    if ( ! ( ReadName(Nf, Buffer, 1000, ':') ) )	    {		Error(EOFINATT, AttName[MaxAtt], "");	    }	    if ( ++MaxAttVal[MaxAtt] >= ValCeiling )	    {		ValCeiling += 100;		Realloc(AttValName[MaxAtt], ValCeiling, String);	    }	    AttValName[MaxAtt][MaxAttVal[MaxAtt]] = CopyString(Buffer);	}	while ( Delimiter == ',' );	/*  Cancel ordered status if <3 real values  */	if ( Ordered(MaxAtt) && MaxAttVal[MaxAtt] <= 3 )	{	    SpecialStatus[MaxAtt] = 0;	}    }}/*************************************************************************//*									 *//*	Locate value Val in List[First] to List[Last]			 *//*									 *//*************************************************************************/int Which(String Val, String *List, int First, int Last)/*  -----  */{    int	n=First;    while ( n <= Last && strcmp(Val, List[n]) ) n++;    return ( n <= Last ? n : First-1 );}/*************************************************************************//*									 *//*	Allocate space then copy string into it				 *//*									 *//*************************************************************************/String CopyString(String S)/*     -----------  */{    char *p;    p = Alloc(strlen(S)+1, char);    strcpy(p, S);    return p;}/*************************************************************************//*									 *//*	Read next char keeping track of line numbers			 *//*									 *//*************************************************************************/int InChar(FILE *f)/*  ------  */{    if ( ! *LBp )    {	LBp = LineBuffer;	if ( ! fgets(LineBuffer, MAXLINEBUFFER, f) )	{	    LineBuffer[0] = '\00';	    return EOF;	}	LineNo++;    }	    return (int) *LBp++;}/*************************************************************************//*									 *//*  Read a raw case description from file Df.				 *//*									 *//*  For each attribute, read the attribute value from the file.		 *//*  If it is a discrete valued attribute, find the associated no.	 *//*  of this attribute value (if the value is unknown this is 0).	 *//*									 *//*  Returns the Description of the case (i.e. the array of		 *//*  attribute values).							 *//*									 *//*************************************************************************/#define XError(a,b,c)	Error(a,b,c)Description GetDescription(FILE *Df, Boolean Train)/*          --------------  */{    Attribute	Att;    char	name[1000], *endname;    int		Dv;    Description	Dummy, DVec;    ContValue	Cv;    Boolean	FirstValue=true;#if defined WIN32  && ! defined _CONSOLE     extern int	XREF;#endif    if ( ReadName(Df, name, 1000, '\00') )    {	Dummy = AllocZero(MaxAtt+2, AttValue);	DVec = &Dummy[1];	ForEach(Att, 1, MaxAtt)	{	    if ( AttDef[Att] )	    {		DVec[Att] = EvaluateDef(AttDef[Att], DVec);		if ( Continuous(Att) )		{		    CheckValue(DVec, Att);		}		if ( SomeMiss )		{		    SomeMiss[Att] |= Unknown(DVec, Att);		    SomeNA[Att]   |= NotApplic(DVec, Att);		}		continue;	    }	    /*  Get the attribute value if don't already have it  */	    if ( ! FirstValue && ! ReadName(Df, name, 1000, '\00') )	    {		XError(HITEOF, Fn, "");		FreeLastCase(DVec);		return Nil;	    }	    FirstValue = false;	    if ( Exclude(Att) )	    {#if defined WIN32 && ! defined _CONSOLE		if ( XREF || Att == LabelAtt )#else		if ( Att == LabelAtt )#endif		{		    /*  Record the value as a string  */		    SVal(DVec,Att) = CopyString(name);		}	    }	    else	    if ( ! strcmp(name, "?") )	    {		/*  Set marker to indicate missing value  */		DVal(DVec, Att) = UNKNOWN;		if ( SomeMiss ) SomeMiss[Att] = true;	    }	    else	    if ( Att != ClassAtt && ! strcmp(name, "N/A") )	    {		/*  Set marker to indicate not applicable  */		DVal(DVec, Att) = NA;		if ( SomeNA ) SomeNA[Att] = true;	    }	    else	    if ( Discrete(Att) )	    {		/*  Discrete attribute  */		Dv = Which(name, AttValName[Att], 1, MaxAttVal[Att]);		if ( ! Dv )		{		    if ( StatBit(Att, DISCRETE) )		    {			if ( Train )			{			    /*  Add value to list  */			    if ( MaxAttVal[Att] >= (int) AttValName[Att][0] )			    {				XError(TOOMANYVALS, AttName[Att],					 (char *) AttValName[Att][0] - 1);				Dv = MaxAttVal[Att];			    }			    else			    {				Dv = ++MaxAttVal[Att];				AttValName[Att][Dv]   = CopyString(name);				AttValName[Att][Dv+1] = "<other>"; /* no free */			    }			}			else			{			    /*  Set value to "<other>"  */			    Dv = MaxAttVal[Att] + 1;			}		    }		    else		    {			XError(BADATTVAL, AttName[Att], name);			Dv = UNKNOWN;		    }		}		DVal(DVec, Att) = Dv;	    }	    else	    {		/*  Continuous value  */		if ( TStampVal(Att) )		{		    CVal(DVec, Att) = Cv = TStampToMins(name);		    if ( Cv >= 1E9 )	/* long time in future */		    {			XError(BADTSTMP, AttName[Att], name);			DVal(DVec, Att) = UNKNOWN;		    }		}		else

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩欧美的一区二区| 亚洲色图19p| av高清久久久| 国产麻豆精品在线| 激情图区综合网| 国产专区综合网| 成人av网站免费观看| 欧美日韩在线播放| 国产日韩精品一区二区三区| 国产精品国产三级国产普通话三级| 精品动漫一区二区三区在线观看| 欧美日韩美女一区二区| 国产精品一二三| 九九在线精品视频| 亚洲一区二区三区视频在线 | 男女男精品视频网| 亚洲二区视频在线| 亚洲第一狼人社区| 亚洲第一久久影院| 老司机一区二区| 国产一区啦啦啦在线观看| 国产白丝精品91爽爽久久| 成人午夜碰碰视频| 91高清视频在线| 欧美欧美欧美欧美首页| 欧美一区在线视频| 国产亚洲福利社区一区| 综合久久一区二区三区| 一区二区三区四区乱视频| 午夜欧美视频在线观看| 激情综合一区二区三区| 不卡高清视频专区| 欧美亚洲国产一区在线观看网站 | 日本一区二区电影| 精品少妇一区二区三区 | 亚洲欧美日韩国产手机在线| 亚洲三级理论片| 日韩电影在线免费看| 久久亚洲精华国产精华液| 中文字幕一区免费在线观看| 国产一区福利在线| 国产亚洲一本大道中文在线| 韩国成人在线视频| 国产精品欧美一级免费| 久久国产精品色| 91视频.com| 欧美精品电影在线播放| 日韩一二三四区| 国产精品视频一二三| 亚洲一区二区三区小说| 国产精品一线二线三线| 9久草视频在线视频精品| 日韩视频一区二区三区在线播放| 久久久99精品久久| 亚洲影院在线观看| 激情综合网最新| 91色综合久久久久婷婷| 精品毛片乱码1区2区3区| 中文字幕日韩精品一区| 免费成人深夜小野草| 不卡区在线中文字幕| 日韩精品一区二区三区四区| 成人免费在线播放视频| 久草这里只有精品视频| 欧美性大战久久久久久久| 国产亚洲一本大道中文在线| 日韩和欧美一区二区三区| 成人性色生活片| 精品国产亚洲一区二区三区在线观看| 亚洲激情欧美激情| 国产成+人+日韩+欧美+亚洲| 欧美电影一区二区三区| 最好看的中文字幕久久| 国产一区二区在线观看视频| 欧美日韩激情一区二区三区| 最新国产精品久久精品| 国模套图日韩精品一区二区| 欧美喷潮久久久xxxxx| ㊣最新国产の精品bt伙计久久| 久久精品国产澳门| 91精品国产高清一区二区三区蜜臀| 国产精品久久久久久久久久免费看| 精品一区二区av| 91超碰这里只有精品国产| 欧洲激情一区二区| 亚洲国产日韩a在线播放| 国产精品色哟哟| 久久av资源网| 日韩欧美在线观看一区二区三区| 青椒成人免费视频| 中文字幕免费不卡| 欧美日韩三级一区| 91亚洲男人天堂| 一本色道**综合亚洲精品蜜桃冫| 国产精品一区二区你懂的| 久久99精品久久久久久久久久久久| 香蕉久久一区二区不卡无毒影院| 性久久久久久久久| 麻豆成人在线观看| 另类调教123区| 亚洲一区二区视频在线| 日韩免费高清电影| 色哟哟日韩精品| 另类调教123区| 一区二区在线看| 久久先锋影音av鲁色资源网| 99精品国产一区二区三区不卡| 亚洲精品在线免费播放| 欧美一区二区三区白人| 午夜精品一区二区三区电影天堂| 欧美性色欧美a在线播放| 亚洲毛片av在线| 欧美亚洲免费在线一区| 亚洲国产wwwccc36天堂| 欧美日韩在线直播| 五月婷婷色综合| 欧美精品在线视频| 热久久一区二区| 精品久久久久av影院| 国产乱码字幕精品高清av | 日韩欧美综合在线| 青青草一区二区三区| 日韩午夜中文字幕| 黄色日韩网站视频| 久久免费看少妇高潮| 国产成人av一区二区| 国产精品女上位| 91亚洲国产成人精品一区二区三| 亚洲制服丝袜av| 日韩一区二区免费电影| 国产毛片精品一区| 精品久久人人做人人爰| 国产精品三级电影| 久久只精品国产| 国产精品免费aⅴ片在线观看| 精品福利一区二区三区免费视频| 在线看一区二区| 欧美亚洲综合另类| 精品黑人一区二区三区久久| 欧美国产乱子伦| 一区二区三区欧美| 在线综合亚洲欧美在线视频| 国产亚洲欧美一区在线观看| 亚洲国产精品一区二区久久| 国产精品白丝av| 欧美一区日本一区韩国一区| 国产日产欧美一区二区视频| 国产一区二区三区免费在线观看| 在线观看日韩高清av| 欧美男同性恋视频网站| 欧美福利电影网| 精品国产区一区| 国产网站一区二区| 亚洲精品久久久久久国产精华液| 亚洲男人天堂av| 亚洲成av人片在线| 国产.精品.日韩.另类.中文.在线.播放| 亚洲精品一区二区在线观看| 久久亚洲综合色| 白白色 亚洲乱淫| 午夜精品福利在线| 日本一区二区三区电影| 欧美日韩一区二区欧美激情 | 中文字幕精品一区二区三区精品| 在线精品视频免费播放| 免费不卡在线观看| 一区二区三区不卡在线观看| 欧美色电影在线| 国产精品一区三区| 亚洲1区2区3区4区| 国产精品久久久久久妇女6080| 日韩午夜在线影院| 91麻豆国产精品久久| 国产黄色91视频| 丝袜国产日韩另类美女| 国产精品久久久久三级| 精品国内二区三区| 在线观看欧美精品| 国产91在线看| 亚洲一区二区视频在线观看| 国产精品美日韩| 久久这里都是精品| 欧美日韩精品一区视频| 一本色道亚洲精品aⅴ| 国产美女久久久久| 乱一区二区av| 日韩电影在线看| 一区二区三国产精华液| 亚洲欧洲日产国码二区| 精品乱人伦小说| 91精品综合久久久久久| 欧美亚洲高清一区二区三区不卡| 国产成人综合网| 国产在线视视频有精品| 首页国产欧美久久| 视频一区二区三区中文字幕| 亚洲女同女同女同女同女同69| 久久久久高清精品| 一本一道久久a久久精品| 91视频一区二区|