updated readme
[BS_AY250.git] / week3 / readme
blobcc0942d71168c989375a80fd3f743b161d082d7f
2 AY250 HW3
3 Author:  Bryan Steinbach
5 Dependencies:  Python 2.6.4, numpy 1.4.1, scipy 0.8.0b1, matplotlib 0.99.3
8 Problem 1:
9   I did not attend class on Monday, so no partner, and no reverse engineering portion to the exercise.  However, I'm delighted to learn of the SimpleXMLRPCServer / xmlrpclib, because one of the instruments I use is controlled by a homegrown XML RPC library written by collaborators.  It had no error propagation of exceptions back to the client, and fun surprises like an assumption that messages will be less than 500 characters.  They'd even written their own JSON parser, which had one bizarre bug that caused algorithms to run for twice as long as if they were run directly.  Looking forward to discarding a couple thousand lines of buggy code with the xmlrpc library.
11 Abstractions for handling images and marshalling are in image.py
12 client and server in client.py and server.py
13 output data in problem1/client_data and problem1/server_data
15 Problem 2:
17 Strategy:
18    * Extract left channel from stereo
19    * Compute power spectrum for whole timestream
20    * Find and fit to peak frequencies
21    * Discard peaks too far from a properly tuned note
22    * Sort peaks by ascending frequency
23    * Pick fundamentals to be peaks which can't be explained as harmonics of a lower note
25 Detected notes are in text files in problem2/output
26 The program does not detect both notes in file 2 that are there according to Chris.  There appears to be some chorus, probably amplitude modulation based, which creates dim tones adjacent to the main tones and causes some pitch confusion.  There are a lot of ways this could be corrected; if it's amplitude modulation, the left right channels might be quadrature, so they could be combined to eliminate the chorus.  The program also does not use amplitude information intelligently, and the results are sensitive to the amplitude threshold used in peak discrimination.