Skip to content

Automatically edit video (non-destructively) by analyzing audio, cut out silence, and import straight into davinci resolve!

License

Notifications You must be signed in to change notification settings

YourAverageMo/auto-silence-cut

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Davinci Resolve FREE Auto Silence Cut

Automatically edit video (non-destructively) by analyzing audio, cut out silence, and import straight into davinci resolve!

  • Analyze video based off of multiple audio tracks
  • Edit out silence with adjustable margins
  • Completely free and runs locally within Davinci Resolve (even on free version)
  • 100% Non-destructive
  • Process multiple clips simultaneously
  • Highlight silent and non-silent parts in timeline
  • Automatically create timeline with subclips ready to edit!

Note

Works best with well processed audio (clearly defined silent parts). Currently there is no threshold adjustment though this is a feature im looking to including.

Love it? Wanna Support?

"Buy Me A Coffee"

github-stars-logo_Color

Table of Contents

Usage Guide

Step 1: Add Clips to the 'Master' Folder

Step1

Drag and drop all the clips you want Auto-Silence-Cut to process into the 'MASTER' folder in DaVinci Resolve.

Note: The current version of Auto-Silence-Cut processes all video files in the 'MASTER' folder.

Although you can process multiple clips simultaneously, it's recommended to only do a few at a time in case something goes wrong. Additionally, having too many clips on the timeline can cause DaVinci Resolve to slow down.

Step 2: Open the Console

Workspace -> Console

Step 3: Open Auto-Silence-Cut

Workspace -> Scripts -> Auto-Silence-Cut

Step 4: Adjust Settings

A popup window will appear, allowing you to configure how Auto-Silence-Cut processes the video files. Refer to the Settings Explained section for detailed explanations of each option.

Settings are automatically saved upon closing in the following location: Documents\Auto Editor\settings.json

The next time you run Auto-Silence-Cut, it will load the previously used settings. This is especially important for how the "Skip this window" option behaves.

If the settings.json file is missing or has been deleted, default settings will be restored and saved to the same location.

Step 5: Click 'START'

Step5

When you're ready, click 'START' and avoid using the keyboard or mouse while Auto-Silence-Cut runs. The script will automatically insert the edited (non-destructive) clips into the timeline, and any input during this time could interfere with that process.

The duration of this process depends on how much footage you are processing. For optimal performance, it's recommended to process no more than 45 minutes of footage at a time to prevent DaVinci Resolve from lagging.

Once the process is complete, a message will appear in the console, and the Auto-Silence-Cut window will close automatically.

Step 6: Adjust Subclips

Step6

After Auto-Silence-Cut has added the subclips to the timeline, you can adjust them as needed. Since this process is non-destructive, all subclips reference the original source material, allowing you to extend or contract the handles of each subclip.

If you're unfamiliar with this, refer to the provided GIF for guidance.

  • Silent Clips: These clips will have no color.
  • Sound Clips: Clips where sound was detected will be highlighted with the color selected in the settings (Highlight Color, default is Orange).

Step6 2

Step 7: Remove Silence

Step7

To remove all the silent clips,

Timeline -> Select Clips With Color -> Default Color

This will select and highlight all the silent clips in the timeline and from there you can just ripple delete all of them to leave no gaps.

Requirements

To ensure full functionality of this project, please follow the steps below to install each required dependency. If you're new to coding or Python, each step includes detailed instructions to help you get started.

1. Install Python 3.7+

This project requires Python 3.7 or higher.

  • Step 1: Visit the official Python download page and click the button to download the latest version.
  • Step 2: Open the downloaded file and follow the installation instructions.
  • Step 3: During installation, make sure to check the box that says "Add Python to PATH"
  • Step 4: Once installed, open your command line (e.g., Command Prompt, Terminal) and type the following command to confirm Python is installed:
    python --version
    You should see a version number (e.g., Python 3.10.5) this means python was successfully installed.

2. Install Auto-Editor

Auto-Editor is a tool that helps with automatic video editing, which is a dependency for this project.

  • Step 1: Open your command line (Command Prompt on Windows, Terminal on Mac).
  • Step 2: Enter the following command to install Auto-Editor:
    pip install auto-editor
  • Step 3: After the installation completes, check that Auto-Editor is installed by typing:
    auto-editor --help
    If the command is recognized, you’re all set. If you see an error, try restarting your command line or refer to the Auto-Editor documentation for help.

Installation

Once you have the required dependencies installing Auto-Silence-Cut is as simple as downloading Auto-Silence-Cut.py and placing it in your scripts folder for DaVinci Resolve.

For Windows: %PROGRAMDATA%\Blackmagic Design\DaVinci Resolve\Fusion\Scripts\Utility

For Mac: /Library/Application Support/Blackmagic Design/DaVinci Resolve/Fusion/Scripts/Utility

Settings Explained

  • LEFT TRIM MARGIN: The amount of padding, in seconds, to leave before the edit (the left of detected audio)
  • RIGHT TRIM MARGIN: The amount of padding, in seconds, to leave after the edit (the right of detected audio)
  • HIGHLIGHT COLOR: The color of sound clips
  • EDIT BASED ON THESE TRACKS: Which audio tracks to use to search for silence. (multiple allowed)
  • SKIP THIS WINDOW: If checked, next time the script is launched GUI will be skipped and processing will begin immediately. Use this if you always use the same settings.

FAQ

Is multi-track audio supported?

Yes, silence detection across multiple audio tracks is allowed. Select which audio tracks you would like to process in the pop-up window.

Can I process multiple clips at once?

Yes, you can process multiple clips simultaneously by adding them to the 'MASTER' folder. However, for optimal performance and to avoid potential issues, it's recommended to only process a few clips at a time.

Where are my settings saved?

Auto-Editor saves settings automatically to:

Documents\Auto Editor\settings.json

These settings are loaded the next time you run Auto-Editor. If the file is deleted or missing, default settings are restored and saved.

How do I remove silent clips from the timeline?

After Auto-Editor adds the subclips to the timeline, silent clips are highlighted with no color. You can remove them by selecting:

Timeline -> Select Clips With Color -> Default Color

This selects all silent clips, allowing you to ripple-delete them and remove gaps from your timeline.

Can I adjust clips after Auto-Editor runs?

Yes, since the process is non-destructive, all subclips reference the original source material. You can extend or contract the handles of each subclip as needed.

I ran the script but nothing happened?

Open up the console in DaVinci Resolve and check why. I tried to code in as much user-friendly error handling as possible but if you still have trouble feel free to open up an issue.

Contribute

If you got a fix in mind or feel like you could improve upon Auto-Silence-Cut feel free to make a fork of this repo, create a new branch, and submit a pull request. As long as the code is well documented and readable, I'd love to see it through!

The Resolve API is very hard to navigate so here are some helpful resources:

Known Issues

  • sometimes extra tracks are created when creating new timeline. No idea why this is happening but I think its a DR problem.

  • there is a case where sometimes the output timeline will be slightly shorter than the original file by a frame or two. I believe this is something to do with the way auto-editor handles cuts.

About

Automatically edit video (non-destructively) by analyzing audio, cut out silence, and import straight into davinci resolve!

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages