<commit_before># Created by: <NAME>
# 13 Dec 2012
# An asyncronous job for transcoding video files using FFMpeg

class TranscodeVideoJob < FfmpegTranscodeJob
  def queue_name
    :video
  end

  def process
    encode_mp4()
    encode_webm()
  end

  private 

  def encode_webm
    opts = "#{size_attributes}  -b:v 345k -acodec libvorbis #{audio_attributes}"
    encode_datastream('webm', 'video/webm', opts)<commit_msg>Trying to generate more keyframes<commit_after># Created by: <NAME>
# 13 Dec 2012
# An asyncronous job for transcoding video files using FFMpeg

class TranscodeVideoJob < FfmpegTranscodeJob
  def queue_name
    :video
  end

  def process
    encode_mp4()
    encode_webm()
  end

  private 

  def encode_webm
    # -g 30 enforces keyframe generation every second (30fps)
    # -b:v is the video bitrate
    # -acodec is the audio codec
    opts = "#{size_attributes}  -g 30 -b:v 345k -acodec libvorbis #{audio_attributes}"
    encode_datastream('webm', 'video/webm', opts)
{'fraction_non_alphanumeric': 0.08241206030150754, 'fraction_numerical': 0.02613065326633166, 'mean_word_length': 3.6542056074766354, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2255547', 'n_tokens_mistral': 368, 'n_tokens_neox': 335, 'n_words': 105}