Skip to main content

Convert transcriptions from rev into FAVE format.

Project description

rev-reader

Parse Json of transcriptions from rev into FAVE-align format and write to CSV.

TOC

  1. Install
  2. How to use
  3. Notes

Install

Pip install as outlined above.

How to use

Built in Python 3.6.5, should work with Python 2 as well.

  1. Run from the command line, option I

    python -m rev_reader.rev_reader $INPUT_FOLDER $ADDITIONAL_OFFSET

    where

    • $INPUT_FOLDER is a path to a directory containing some JSON files of rev annotations. The output CSVs will be written to the same directory. This is a required argument.

    • $ADDITIONAL_OFFSET is a number that will be added to / subtracted from the timestamps before the data is output as CSV. This is an optional argument.

    For example, the command below will convert all the JSON files in the folder annotated_files and subtract 0.01 from each time stamp. It will write CSV files to folder annotated_files.

    python -m rev_reader.rev_reader /home/patrick/Documents/annotated_files -.01

  2. Run from the command line, option II

    You can run the rev_reader.py file directly by executing:

    python $PATH_TO_REV_READER.PY $INPUT_FOLDER $ADDITIONAL_OFFSET

    For example, the command below will convert all the JSON files in the folder annotated_files . It will write CSV files to folder annotated_files.

    e.g. python rev_reader.py /home/patrick/Documents/annotated_files -.01

  3. Import into Python

    You can access the functions directly from Python by doing

    import rev_reader

    Refer to the Github docs for info.

Notes

  1. The naming scheme for CSVs is $LOWERCASE_NAME_OF_INPUT_JSON + $TIMESTAMP + "_faved.csv"

    For example, for input file BE.TO.017.json, the CSV file will be be.to.017_20181124-1819_faved.csv

  2. Dependencies: pandas

Project details


Release history Release notifications

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
rev_reader-0.0.3-py3-none-any.whl (9.4 kB) Copy SHA256 hash SHA256 Wheel py3
rev-reader-0.0.3.tar.gz (4.6 kB) Copy SHA256 hash SHA256 Source None

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page