Skip to content

Latest commit

 

History

History
127 lines (84 loc) · 2.78 KB

README.md

File metadata and controls

127 lines (84 loc) · 2.78 KB
  __ _     _      _ _ _
 / _(_) __| | ___| (_) |_ _   _
| |_| |/ _` |/ _ \ | | __| | | |
|  _| | (_| |  __/ | | |_| |_| |
|_| |_|\__,_|\___|_|_|\__|\__, |
                          |___/

Welcome to Fidelity

Fidelity will run audio strategies comprised of a plethora of other audio tools.

Run Tests

rspec

Debugging

When running fidelity from the commandline, prepend this to enable full stack traces on errors:

DEBUG=1 fidelity ...

Installation

Add this line to your application's Gemfile:

gem 'fidelity'

And then execute:

$ bundle

Or install it yourself as:

$ gem install fidelity

Usage

CLI

fidelity run <manifestfile>

fidelity analyze <directory>

fidelity process <s3-bucket>

Code

Fidelity::ChainRunner.new(path).run(logger)

While

  • path - a path to manifest file
  • logger - optional, if given should be an instance of Logger

In most cases you will want to subclass the ChainRunner to make use of its callbacks.

The Gory Details

The manifest file should contain the following:

---
:id: <id>
:chain:
  - precursor
  - kluuu_merge
  - m4a
  - ogg
  - mp3
  - ...
:talk_start: <timestamp>
:talk_stop: <timestamp>
:cut_conf:
  - start: <offset>
    end: <offset>
  - start: <offset>
    end: <offset>
  - ...

Where...

  • Timestamps are down to seconds (not milliseconds!).
  • Offsets are down to milliseconds and are relative to the beginning.
  • cut_conf may be nil, an empty Array or omited entirely
  • chain is a list of strategy names, either as array or as space separated string

Available Strategies

TODO

  • further improve debugging and logging
  • use slop or docopt

NOTES

List durations of flv files, e.g.

ls -1 app/shared/recordings/t3338* | xargs -n 1 -irpl ffmpeg -i rpl 2>&1 | grep Duration