Skip to content

This is not really a grading script, rather, this is the simplest version of a super client (who has the power of starting a server...)

Notifications You must be signed in to change notification settings

PatriciaXiao/CS131-Project-Sample-Grading-Script

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CS131 Project Sample Grading Script

  • Maintained and updated on CS131 TA Organization Reporitory since Winter 2020.
  • This is not really a grading script because you didn't see any grading
  • The evaluation giving you True / False something is somewhat partial credits for each task
  • This is the simplest version of the core part of the grading script, but it doesn't contain any real test case
  • You may regard it as a super client (who has the power of starting a server) as well.

Background

Resource

  • Thanks to previous-year TA, Wenhao's code
  • Following discussion online, to kill the process occupying port 8000 we could run:
    lsof -ti:8000 | xargs kill
  • To run a script in the background I used nohup
  • To execute command line within Python:
    import os
    os.system('sox input.wav -b 24 output.aiff rate -v -L -b 90 48k')
  • under hint code repo I put my hint code for you to get started with this project there.

Usage

  • put your server.py and all other needed .py files under the sample_submission folder
  • modify the port number in client_basic.py (or keep them the same if you run on local machine --- the easiest way to test your code is to change your port number to around 800X and then test them on your local machine)
  • could run single evaluation by
    python client_basic.py
  • I think it should work for mac and linux, probably won't work on Windows
  • Probably a little bit adaptation is needed, probably the version matters
  • Probably some mistake in this readme... I was too tired when I wrote this
  • Once it works, feel free to add your own test cases in client_basic.SuperClient.test; it's easy isn't it?

About organizing log files

You might want to have a look at os.mkdir and os.path.exists

What kind of submission is safe?

If you unzip your files into the sample_submission folder, with no extra effort required (e.g. don't need to create an empty folder manually, etc.), we can always make client_basic run (I mean if you occupy others' port then it is not guaranteed to work).

About

This is not really a grading script, rather, this is the simplest version of a super client (who has the power of starting a server...)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages