Skip to content

sherryt63/AI_Lab5

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

AI_Lab5

你好!这是《当代人工智能》课程实验五的作业仓库😊(请参考master分支噢!!)

代码环境

此代码使用版本为3.10.6的python语言实现,同时需要用如下命令安装相应模块:

pip install -r requirements.txt

仓库文件结构

本仓库由如下所示的文件和文件夹组成:

|-- lab5.py                    #code for this project
|-- 实验五数据     # a file folder for the data this lab needs(.zip version)
    |-- data/     # including text data and image data for this project
    |-- test_without_label.txt # the file we need to test by model 
    |-- train.txt              # the file used to train our model
|-- requirements.txt           # including all the python modules needed
|-- readme.md                  # introducing this repository

##代码执行流程

  1. 把本仓库的所有文件下载到一个名为AI_lab5的大文件夹下,并进入:
cd AI_lab5
  1. 确保自己的python版本在3.10.6左右,并下载所需模块:
python --version
pip install -r requirements.txt
  1. 用类似如下的语句运行模型,可自行调整命令行参数(此处假设AI_lab5文件夹直接下载到C盘):
python lab5.py --epochs 10 --batch_size 16 --learning_rate 1e-5 --data_path r"C:\AI_lab5\实验五数据\data" --train_file r"C:\AI_lab5\实验五数据\train.txt" --test_file r"C:\AI_lab5\实验五数据\test_without_label.txt"
  1. 观察实验结果即可

参考的库

本代码主要参考了如下两个对数据进行处理的库:

About

a repository for lab5 files of AI class

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages