Showing the changes to python (1 of 1 file). Show all
Unified · Split
| @@ -51,14 +51,9 @@ def parse_args(): · 50 unmodified lines | ||
| 51 | 51 | parser.add_option("-S","--silencecut", |
| 52 | 52 | action="store_true", dest="silencecut", default=False, |
| 53 | 53 | help="outputs silence locations") |
| 54 | − # to be implemented | |
| 55 | − | |
| 56 | 54 | parser.add_option("-z","--zerocross", |
| 57 | − action="store_true", dest="zerocross", default=False, | |
| 58 | − help="NOT IMPLEMENTED zero crossing matching") | |
| 59 | − parser.add_option("-b","--beat", | |
| 60 | − action="store_true", dest="beat", default=False, | |
| 61 | − help="NOT IMPLEMENTED output beat locations") | |
| 55 | + action="store", dest="zerothres", default=0.008, | |
| 56 | + help="zero-crossing threshold for slicing [default=0.008]") | |
| 62 | 57 | # plotting functions |
| 63 | 58 | parser.add_option("-p","--plot", |
| 64 | 59 | action="store_true", dest="plot", default=False, |
| @@ -72,6 +67,10 @@ def parse_args(): · 7 unmodified lines | ||
| 72 | 67 | parser.add_option("-q","--quiet", |
| 73 | 68 | action="store_false", dest="verbose", default=False, |
| 74 | 69 | help="be quiet") |
| 70 | + # to be implemented | |
| 71 | + parser.add_option("-b","--beat", | |
| 72 | + action="store_true", dest="beat", default=False, | |
| 73 | + help="NOT IMPLEMENTED output beat locations") | |
| 75 | 74 | (options, args) = parser.parse_args() |
| 76 | 75 | if not options.filename: |
| 77 | 76 | print "no file name given\n", usage |
| @@ -133,4 +132,4 @@ if options.plot: · 55 unmodified lines | ||
| 133 | 132 | samplerate=samplerate, hopsize=hopsize, outplot=options.outplot) |
| 134 | 133 | |
| 135 | 134 | if options.cut: |
| 136 | − cutfile(filename,onsets,bufsize=bufsize,hopsize=hopsize) | |
| 135 | + cutfile(filename,onsets,zerothres=zerothres,bufsize=bufsize,hopsize=hopsize) | |