EADST

Python: Merge Images to the Video with OpenCV

Python: Merge Images to the Video with OpenCV

import os
import cv2

image=cv2.imread("./result/img0001.jpg")
save_prefix = "./test_mp4/"
image_info=image.shape
height=image_info[0]
width=image_info[1]
size=(height,width)
print(size)
fps=24
fourcc=cv2.VideoWriter_fourcc(*"mp4v")
video = cv2.VideoWriter('video_name.mp4', cv2.VideoWriter_fourcc(*"mp4v"), fps, (width,height)) 

for root, dirs, files in os.walk(save_prefix):
    files = sorted(files)
    for img in files:
        file_name = os.path.join(root, img)
        image=cv2.imread(file_name)
        video.write(image)
相关标签
About Me
XD
Goals determine what you are going to be.
Category
标签云
RAR 关于博主 Augmentation 第一性原理 Quantize Breakpoint TTS CTC ChatGPT TensorFlow Docker IndexTTS2 Qwen2.5 CAM Disk AI GGML Pickle 公式 Vmess Jev Animate logger Bin v2ray tqdm ONNX RL Markdown 飞书 ModelScope 报税 transformers Proxy uWSGI Sklearn Bitcoin 算法题 SQL 顶会 Agent PIP 继承 BeautifulSoup git TSV HuggingFace BF16 财报 Plotly Distillation uwsgi Pillow Paper BTC mmap Pandas XML SVR 搞笑 Search Safetensors VSCode hf Magnet Datetime COCO CLAP 域名 Data UI Qwen Linux CC Attention CV Heatmap Interview GIT Pytorch 签证 Math FP16 VPN Dataset NLTK JSON Hilton UNIX Web API CEIR EXCEL ResNet-50 Llama Image2Text 多线程 Review Algorithm Input Card 音频 NameSilo FP64 Github HaggingFace ms-swift WAN Firewall OpenAI CUDA LLM Zip Diagram Video Streamlit Bert Miniforge Tracking printf DeepStream FlashAttention Quantization Vim OpenCV git-lfs LeetCode Nginx Food Google TensorRT API网关 Template WebCrawler SQLite Anaconda Shortcut 论文速读 Paddle Cloudreve Permission MD5 FastAPI PyTorch Python FP32 Bipartite Plate LLAMA InvalidArgumentError diffusers Random Website icon RGB Conda 论文 Django GoogLeNet 强化学习 FP8 Claude Domain 自我改进 Jetson NLP 图标 XGBoost Mixtral Windows Transformers Translation GPT4 C++ 图形思考法 Knowledge 多进程 Clash Gemma Color 递归学习法 torchinfo scipy Tiktoken tar 长期记忆 Ptyhon SPIE Hungarian Michelin 腾讯云 Hotel Excel Crawler VGG-16 SAM Harness Rebuttal Jupyter GPTQ 版权 个人博客 Freesound QWEN Land DeepSeek Tensor Use 阿里云 PyCharm YOLO Base64 LaTeX 净利润 PDF v0.dev Statistics Numpy PDB llama.cpp Logo 云服务器 Qwen2 Git OCR LoRA 证件照 Ubuntu Password CSV News Baidu
站点统计

本站现有博文340篇,共被浏览1005173次

本站已经建立2714天!

热门文章
文章归档
回到顶部