view cherry1.py @ 11:15260ae0d6bc

• modified html templates for audio environment classification experiment (10 audio files and 10 classes for each test page) • modidfied cherryFxTest to be consistent with audio templates and to include files from AASPAudio • included AASPAudio (recordings for audio environment classification)
author Daniele Barchiesi <daniele.barchiesi@eecs.qmul.ac.uk>
date Mon, 11 Mar 2013 13:31:44 +0000
parents 032bc65ebafc
children
line wrap: on
line source
import cherrypy
from cherrypy.lib.static import serve_file

class OnePage(object):
	def index(self):
		return "one page!"
	index.exposed = True


class TwoPage(object):
	def index(self):
		return serve_file('/Users/tmc/write_it.txt', "audio/mpeg", "attachment")
	index.exposed = True
 
class HelloWorld(object):
	onepage = OnePage()
	twopage = TwoPage()
 
	def index(self):
		return "hello world"
	index.exposed = True
 
cherrypy.quickstart(HelloWorld())