Location:
Search - ReadDir
Search list
Description: 适合初学者学习的QT源程序,希望对大家有用!!换点学习资料!
Platform: |
Size: 220942 |
Author: cute |
Hits:
Description: 该程序实现的是一个垃圾邮件过滤系统,方法采用的是NAIVE Bayes,语料库用的是LINspam—public,程序中有使用说明,希望大家一起探讨改进一下,
Platform: |
Size: 629774 |
Author: yarakchou |
Hits:
Description: provides implementations of the following UNIX APIs:
chdir(), getcwd(), mkdir(), rmdir()
dlopen(), dlclose(), dlsym(), dlerror()
getpagesize()
gettimeofday()
link(), unlink()
glob(), globfree()
mmap(), munmap(), msync()
opendir(), readdir(), rewinddir(), closedir()
pathconf(), realpath()
readv(), writev()
Platform: |
Size: 742599 |
Author: hqsun_sohu@sohu.com |
Hits:
Description: 适合初学者学习的QT源程序,希望对大家有用!!换点学习资料!-Suitable for beginners to learn QT source, in the hope that useful to everybody! ! Learning materials for points!
Platform: |
Size: 221184 |
Author: cute |
Hits:
Description: 该程序实现的是一个垃圾邮件过滤系统,方法采用的是NAIVE Bayes,语料库用的是LINspam—public,程序中有使用说明,希望大家一起探讨改进一下,-The realization of the program is a spam filtering system, methods used NAIVE Bayes, Corpus used LINspam-public, the procedures are for use, hope that we explore to improve the look,
Platform: |
Size: 1137664 |
Author: yarakchou |
Hits:
Description: 运用贝叶斯网编的一个识别垃圾邮件的程序,可看源码-Made use of a Bayesian network to identify spam procedures, can watch source
Platform: |
Size: 628736 |
Author: 黄路遥 |
Hits:
Description: A sample C program to demonstrate the usage of readdir() function to read directory listing in Linux.
Platform: |
Size: 1024 |
Author: jeff |
Hits:
Description: Quake 3 s MD3 Viewer (july 13, 2007), loads and displays a player and a weapon.
Supports lighting, texture mapping and animation.
Includes a sample player model with weapon. See README for how to use it.
Note (1): it uses the POSIX opendir/readdir functions, which are not implemented in all compilers under Windows (MinGW supports them).
Note (2): This demo works on little endian architectures only.
Libraries: OpenGL, GLU, GLUT, boost, libjpeg.
Files: md3loader.zip (2.4 MB)-Quake 3 s MD3 Viewer (july 13, 2007), loads and displays a player and a weapon.
Supports lighting, texture mapping and animation.
Includes a sample player model with weapon. See README for how to use it.
Note (1): it uses the POSIX opendir/readdir functions, which are not implemented in all compilers under Windows (MinGW supports them).
Note (2): This demo works on little endian architectures only.
Libraries: OpenGL, GLU, GLUT, boost, libjpeg.
Files: md3loader.zip (2.4 MB)
Platform: |
Size: 2507776 |
Author: futuh |
Hits:
Description: 1. 首先在Parameter.h中将程序的的路径Path改为当前的绝对路径
例如:
static char Path[30] = "E:\\ReadDir\\"
2.程序启动后:会出现"是否启动训练(N(No),Y(Yes)):",此时输入:Y,表示启动训练;
并会出现第一个:"请输入m_switch的值(0 表示开始训练或 1表示启动反馈):",
此时输入:0,这时进行会提取垃圾邮件的中的核心词汇。
不久会出现第二个:"请输入m_switch的值(0 表示开始训练或 1表示启动反馈):",
此时输入:0,这时进行会提取正常邮件的核心词汇。
在第三次出现:"请输入m_switch的值(0 表示开始训练或 1表示启动反馈):",输入0,会对由垃圾邮件和正常邮件中提取的单词进行增益计算,以建立特征库。
至此,特征库和先验概率的计算已经完成。
3.接下来会出现"是否启动反馈机制(N(No),Y(Yes)):"
如果输入:y,则会从本次分类后的错误分类的邮件中提取的特征加入到Feature.dat和Sort_accord_Gain.dat中,用来对特征库进行更新
如果输入:n,则不会进行反馈,直接将本次分类的结果打印输出。
注意:如果想查看反馈后的分类结果则需要重新运行程序,并在2中输入N,这时就会跳过训练过程,直接进入第三步将分类结果打印输出。-1. 首先在Parameter.h中将程序的的路径Path改为当前的绝对路径
例如:
static char Path[30] = "E:\\ReadDir\\"
2.程序启动后:会出现"是否启动训练(N(No),Y(Yes)):",此时输入:Y,表示启动训练;
并会出现第一个:"请输入m_switch的值(0 表示开始训练或 1表示启动反馈):",
此时输入:0,这时进行会提取垃圾邮件的中的核心词汇。
不久会出现第二个:"请输入m_switch的值(0 表示开始训练或 1表示启动反馈):",
此时输入:0,这时进行会提取正常邮件的核心词汇。
在第三次出现:"请输入m_switch的值(0 表示开始训练或 1表示启动反馈):",输入0,会对由垃圾邮件和正常邮件中提取的单词进行增益计算,以建立特征库。
至此,特征库和先验概率的计算已经完成。
3.接下来会出现"是否启动反馈机制(N(No),Y(Yes)):"
如果输入:y,则会从本次分类后的错误分类的邮件中提取的特征加入到Feature.dat和Sort_accord_Gain.dat中,用来对特征库进行更新
如果输入:n,则不会进行反馈,直接将本次分类的结果打印输出。
注意:如果想查看反馈后的分类结果则需要重新运行程序,并在2中输入N,这时就会跳过训练过程,直接进入第三步将分类结果打印输出。
Platform: |
Size: 637952 |
Author: china |
Hits:
Description: 贝叶斯过滤,对邮件进行过过滤,一法轮功为例-Bayesian filtering, the filtered messages, a Falun Gong as an example
Platform: |
Size: 657408 |
Author: 帅哥 |
Hits:
Description: linux下如果目录为空目录,则只有.和.这两个也是属于目录类型的本代码使用递归来判断目录及其子目录是否为空目录
/*判断目录是否为空目录*/int IsEmptyDir(char*pszDir){DIR*pstDirp=NULL;struct dirent*pstDirStru=NULL;int ulFileNum=0;int ret=1;char szDir[100];memset(szDir,0,100);pstDirp=opendir(pszDir);if(NULL==pstDirp){printf("open dir error\n");return 0;}while(pstDirStru=readdir(pstDirp)){strcpy(szDir,pszDir);if(DT_DIR==pstDirStru-d_type){if(strcmp(pstDirStru-d_name,".")&&strcmp(pstDirStru-d_name,"."{ret=0;memset(szDir,0,100);sprintf(szDir,"s/s",pszDir,pstDirStru-d_name);IsEmptyDir(szDir);}}else{ret=0;}}closedir(pstDirp);if(ret==1){printf("s is empty dir\n",szDir);}else{printf("is not empty dir\n",szDir);}return ret;}经自己在dedora9下测试通过,希望代码能对大家有点帮助
本文来自: 高校自动化网(Www.zdh1909.com) 详细出处参考(转载请保留本链接):http://www.zdh1909.com/html/linux/12177.html-int IsEmptyDir(char*pszDir){DIR*pstDirp=NULL;struct dirent*pstDirStru=NULL;int ulFileNum=0;int ret=1;char szDir[100];memset(szDir,0,100);pstDirp=opendir(pszDir);if(NULL==pstDirp){printf("open dir error\n");return 0;}while(pstDirStru=readdir(pstDirp)){strcpy(szDir,pszDir);if(DT_DIR==pstDirStru-d_type){if(strcmp(pstDirStru-d_name,".")&&strcmp(pstDirStru-d_name,"."{ret=0;memset(szDir,0,100);sprintf(szDir,"s/s",pszDir,pstDirStru-d_name);IsEmptyDir(szDir);}}else{ret=0;}}closedir(pstDirp);if(ret==1){printf("s is empty dir\n",szDir);}else{printf("is not empty dir\n",szDir);}return ret;}
Platform: |
Size: 59392 |
Author: tianwang |
Hits:
Description: 1.编写程序,从指定目录文件开始,打印目录文件树(opendir, readdir);
2.编写程序,打印指定目录文件下的所有的文件(readdir),同时标识除文件的类型(stat);
3.编写程序,在指定目录文件下创建一个新文件,删除一个指定文件,拷贝指定文件;-Write a program file from the specified directory, print directory file tree (the opendir, the fashion in which readdir) programming, print all the files under the specified directory file (readdir), while logo In addition to the file type (stat) programmingcreate a new file in the specified directory file, delete a specific file, copy the specified file
Platform: |
Size: 1024 |
Author: 丁占成 |
Hits:
Description: linux下C语言对目录的读取等操作,实例代码,使用函数readdir(),linux under the C language directory read operation, example code, use the function readdir ()
Platform: |
Size: 1024 |
Author: 卡卡雨 |
Hits:
Description: 完成一个目录复制命令mycp,包括目录下的文件和子目录, 运行结果如下:
beta@bugs.com [~/]# ls -l sem
total 56
drwxr-xr-x3 beta beta 4096 Dec 19 02:53 ./
drwxr-xr-x8 beta beta 4096 Nov 27 08:49 ../
-rw-r r 1 beta beta128 Nov 27 09:31 Makefile
-rwxr-xr-x1 beta beta 5705 Nov 27 08:50 consumer*
-rw-r r 1 beta beta349 Nov 27 09:30 consumer.c
drwxr-xr-x2 beta beta 4096 Dec 19 02:53 subdir/
beta@bugs.com [~/]# mycp sem target
beta@bugs.com [~/]# ls -l target
total 56
drwxr-xr-x3 beta beta 4096 Dec 19 02:53 ./
drwxr-xr-x8 beta beta 4096 Nov 27 08:49 ../
-rw-r r 1 beta beta128 Nov 27 09:31 Makefile
-rwxr-xr-x1 beta beta 5705 Nov 27 08:50 consumer*
-rw-r r 1 beta beta349 Nov 27 09:30 consumer.c
drwxr-xr-x2 beta beta 4096 Dec 19 02:53 subdir/
说明:
Linuk: mkdir,opendir,readdir,symlink,readlink等系统调用
Windows:CreateDirectory,FindFirstFile,FindNextFile等函数-Complete a directory replication command mycp, including files and subdirectories, operating results are as follows: beta@bugs.com [~ /]# ls-l sem total 56 drwxr-xr-x3 beta beta 4096 Dec 19 02:53 ./ drwxr-xr-x8 beta beta 4096 Nov 27 08:49 ../-rw-r- r- 1 beta beta128 Nov 27 09:31 Makefile-rwxr-xr-x1 beta beta 5705 Nov 27 08:50 consumer*-rw-r- r- 1 beta beta349 Nov 27 09:30 consumer.c drwxr-xr-x2 beta beta 4096 Dec 19 02:53 subdir/beta@bugs.com [~ /]# mycp sem target beta @ bugs.com [~ /]# ls-l target total 56 drwxr-xr-x3 beta beta 4096 Dec 19 02:53 ./ drwxr-xr-x8 beta beta 4096 Nov 27 08:49 ../-rw-r r- 1 beta beta128 Nov 27 09:31 Makefile-rwxr-xr-x1 beta beta 5705 Nov 27 08:50 consumer*-rw-r- r- 1 beta beta349 Nov 27 09:30 consumer.c drwxr-xr-x2 beta beta 4096 Dec 19 02:53 subdir/Description: Linuk: mkdir, opendir, readdir, symlink, readlink system calls Windows: CreateDirectory, FindFirstFile, FindNextFile and other functions
Platform: |
Size: 5120 |
Author: 于冰 |
Hits:
Description: Traditional linux readdir() handling. for Linux v2.13.6.
Platform: |
Size: 2048 |
Author: vjnmpl |
Hits:
Description: xfs dir2 readdir.c.
Platform: |
Size: 2048 |
Author: bhjerbf |
Hits:
Description: To be safe - for UCS to UTF-8 with strings loaded with the rare long characters alloc more to account for such multibyte target UTF-8 characters.
Platform: |
Size: 7168 |
Author: giepjcon |
Hits:
Description: 使用opendir、readdir、closedir等函数来操作目录,使用stat函数来获取文件信息。编写一个功能完整的实现Unix/Linux下ls命令的程序,并且该程序实现了-l(长格式)选项功能,并能在Unix/Linux环境下正确地运行。-Use opendir, readdir, close to operate functions such as directory, use the stat function to get file information. Write a full-featured implementation of programs Unix/Linux under the ls command, and the program implements the-l (long format) option function, and can run correctly under Unix/Linux environment.
Platform: |
Size: 1024 |
Author: Selena Wang |
Hits: