Updated: 2023-07-14
AG352-4YED3-0852Q-LPXXT-MGKG4
FC1R0-2EX4M-H854Y-2NWGE-Q2KXA
ZU3EH-0YXD4-4819Q-CFWQZ-MZHX4
import re | |
import subprocess | |
# Función para ejecutar el comando FFmpeg | |
def run_ffmpeg(command): | |
result = subprocess.run(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE) | |
return result.stdout.decode(), result.stderr.decode() | |
# Detectar los silencios en un archivo de audio | |
def detect_silence(input_file): |
projectManager = resolve.GetProjectManager() | |
currentProject = projectManager.GetCurrentProject() | |
media_pool = currentProject.GetMediaPool() | |
timeline = currentProject.GetCurrentTimeline() | |
time_in_seconds = [] #Cambiar por la lista de tiempos que arroje ffmpeg | |
fps = timeline.GetSetting("timelineFrameRate") | |
frame_positions = [int(round(time_sec * float(fps))) for time_sec in time_in_seconds] | |
for frame in frame_positions: | |
timeline.AddMarker(frame, 'Red', 'M1', '', 1) |
projectManager = resolve.GetProjectManager() | |
currentProject = projectManager.GetCurrentProject() | |
media_pool = currentProject.GetMediaPool() | |
timeline = currentProject.GetCurrentTimeline() | |
media_pool_clips = media_pool.GetRootFolder().GetClipList() | |
selected_clip = media_pool_clips[1] | |
timeline_clip = media_pool.AppendToTimeline([selected_clip])[0] | |
clip_width, clip_height = 2560, 1440 |
The timezone of a container can be set using an environment variable in the docker container when it is created. For example:
$ docker run ubuntu:latest date
Sat Feb 27 15:58:32 UTC 2021
$ docker run -e TZ=America/Bogota ubuntu:latest date
Sat Feb 27 15:58:40 Asia 2021