LogoLogo
  • Seahaven
    • Seahaven Documentation
      • Setup Your Account
      • Getting Started
        • Prepare Your Models
          • Name Objects
          • Add Camera Curve to a scene
        • Import 3D Assets
        • Colormap Editor
        • Relationship Editor
          • Start Workflow
            • Workflow
            • Relationship
              • Relationship (Array)
          • Relationships
            • Placements
            • Locate
            • Rotate
            • Neighbour
            • Drop
            • Center
            • Scale
            • Align
            • Attach
            • Put
        • Simulation Editor
          • Workflow
            • Category Visibility Threshold
          • Scene
            • 3D Asset
            • HDRI Lighting
            • Physical Sun/Sky
            • Ground Plane
            • Interior Scene
            • Room Type
          • Relationships
            • Load Relationships
          • Camera
            • Camera Configuration
            • Animated Track Camera
            • Curve-Based Camera
            • Room-Perimeter Camera
              • Category
            • Room-Based Camera
              • Additional Cameras
            • Position Camera
              • Conical
              • Spherical
              • Cubic
            • Orientation
              • Calculate Area of Interest
              • Point
            • Perspectival Camera Properties
            • Fisheye Camera Properties
          • Manipulators
            • Camera Manipulators
              • Override Camera Target
              • Override Camera Position
              • Near IR (Approximation)
              • Track Camera to Object
                • Camera Path Settings
            • Light Manipulators
              • Randomize HDRI Background
              • Modify Light Strength
              • Place Lights
                • Light Object (Bbox)
                • Light Object (Polar)
            • Material Manipulators
              • Randomize Material Color
              • Randomize Material Properties
              • Swap Materials
                • Import Material
                • Replace Material
                • Weighted Material
            • Delete Objects by Name
            • Pose Objects
              • Pose Set
              • Pose Pair
            • Constrain Object
            • Add Particle System
            • Load Object Along Curve
            • Replace
              • View settings
              • Load child object
          • Output
            • Additional Annotation Settings
            • Color Map
            • Camera Ex/Intrinsics
            • Keypoints
            • Normal Map
            • Depth Map
          • Post-Processing
            • Visualize COCO Annotations
            • Shot Noise
            • Glare
            • Disable shadows
        • Running Simulation
        • Save and Import
    • Seahaven Tutorials
    • Errors and Alerts
  • Simulation Manager
    • Simulation Manager
  • Simulation API
    • Simulation Structure
      • Sample Configuration
    • Modules
      • Structure Modules
        • Generator Class
          • generator.Room
            • Submodule: RoomTextureLoader
            • Submodule: RoomLightLoader
            • How To Query Room Properties
            • Sample Room Configuration
        • Loader Class
          • loader.ObjectLoader
      • Placement Modules
        • Placement Class
          • placement.PlacementHandler
            • Placement Rules
              • Settings
      • Lighting Modules
        • Lighting Class
          • lighting.HdriLoader
          • lighting.LightLoader
      • Camera Modules
        • Camera Class
          • camera.CameraSampler
          • camera.RoomCamera
            • Submodule: proximity_checks
            • Submodule: default_cam_param
      • Output Modules
        • Renderer Class
          • renderer.MultiRenderer
            • Submodule: RgbRenderer
            • Submodule: InstanceRenderer
            • Submodule: SemanticRenderer
            • Submodule: DepthRenderer
            • Submodule: BoundingBoxWriter
  • Management API
    • RESTful API
    • Python API
      • Example
    • Python API (V4 - BETA)
      • Installation
      • Merge Datasets
      • Methods
      • Dataset Analysis
      • Compression Artifacts
      • Domain Matching
      • Credentials
  • API Tutorials
    • Residential Interior Simulation
      • Upload Your Placement Rules
      • Modifying Your Camera
      • Modify Placement Rules
      • Run your Simulation
      • Tutorial Materials
        • Pipeline Configuration
        • Placement Rules
          • bedroom1.yaml
          • bedroom2.yaml
          • livingroom.yaml
          • floorPlan.yaml
Powered by GitBook
On this page
  • FFMPEG Encoding
  • Arguments:
Export as PDF
  1. Management API
  2. Python API (V4 - BETA)

Compression Artifacts

Tools for compression artifacts to your simulated data

You can access the compression artifacts tools as follows.

import lexset.compression_artifacts as ca

# Provide the directory path where your images are located
dir_path = "./data/"

FFMPEG Encoding

Compresses a sequence of images using ffmpeg and saves individual frames as PNG files

# Call the function with desired parameters
ca.ffmpeg_encode(
    dir_path=dir_path,
    framerate=30,  # Frame rate for the output video
    codec="libx264",  # Codec to use for the encoded video file
    extension=".mp4",  # Extension for the video file
    bitrate_kbps=5000,  # Target bitrate (kb/s) for the video file
    bitrate_kbps_min=5000,  # Minimum bitrate (kb/s) for the video file
    bitrate_kbps_max=5000,  # Maximum bitrate (kb/s) for the video file
    bufsize=5000,  # Buffer size of the H.264/H.265 video file
    ffmpeg_path="ffmpeg"  # Optional path to ffmpeg executable
)

Arguments:

dir_path="" (default="") : Path to the directory containing the images to be processed framerate=30 (default=30) : Frames per second for the target video codec="libx264" (default="libx264") : Codec to use for the encoded video file. Corresponds to the options available with ffmpeg. extension=".mp4" (default=".mp4"):- Optional extension for the video file. This should correspond with the appropriate codec (e.g. ".mp4" for "libx264") bitrate_kbps=5000 (default=5000) : Target bitrate (kb/s) for the video file bitrate_kbps_min=5000 (default=5000): Minimum bitrate (kb/s) for the video file bitrate_kbps_max=5000 (default=5000): Maximum bitrate (kb/s) for the video file bufsize=5000 (default=5000): Buffer size of the H.264/H.265 video file ffmpeg_path="ffmpeg" (default="ffmpeg"): Optional path to ffmpeg executable. Only necessary if ffmpeg is not added to PATH

PreviousDataset AnalysisNextDomain Matching

Last updated 11 months ago