Skip to content

Reduce duplicate calculations by caching metrics to disk (replacement for load_from_csv) #342

Open
@jucor

Description

@jucor

Hi!

Thanks for a great pacakage.

I notice that StatsManager.load_from_csv now has a deprectation warning. What is now the recommended way to avoid re-running the costly (20 minutes on my 1h20 x265 video) scene detection, please?

I have a stats file created with the CLI:

scenedetect --input myfile.mkv --stats adaptive-stats.csv detect-adaptive

and I would like to load that adaptative-stats.csv file into a SceneManager to do the actual scene detection. load_from_csv sounded promising :)

Thanks for any help, and a great tool!

Environment:

[PySceneDetect] PySceneDetect 0.6.2

System Info
------------------------------------------------------------
OS           macOS-13.4.1-arm64-arm-64bit
Python       3.11.4

Packages
------------------------------------------------------------
av           Not Installed
click        8.1.6
cv2          4.8.0
moviepy      Not Installed
numpy        1.25.1
platformdirs 3.9.1
scenedetect  0.6.2
tqdm         4.65.0

Tools
------------------------------------------------------------
ffmpeg       6.0
mkvmerge     v77.0 ('Elemental') 64-bit

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions