in03 / proxima

Transcode source media directly from DaVinci Resolve using multiple machines for encoding. Great for creating proxies quickly.
MIT License
53 stars 3 forks source link

Improve restore speed #185

Closed github-actions[bot] closed 2 years ago

github-actions[bot] commented 2 years ago

Improve restore speed

Is there some sort of set/comprehension technique

that is faster than multiple nested for loops here?

https://github.com/in03/Resolve-Proxy-Encoder/blob/8d7463037748320b98a9216b137defc30f21e324/resolve_proxy_encoder/queuer/queue.py#L160


    wait_jobs(job_group)

    # Get media pool items back
    logger.debug(f"[magenta]Restoring media-pool-items[/]")

    # TODO: Improve restore speed
    # Is there some sort of set/comprehension technique
    # that is faster than multiple nested for loops here?
    # labels: enhancement

    for x in jobs:
        for y in jobs_with_mpi:
            for k, v in y.items():
                assert hasattr(v, "GetClipProperty()")
                if x["media_pool_item"] == k:
                    x.update({"media_pool_item": v})

    try:

b23c2bebf1706614f4063455e1784d608acb1320

github-actions[bot] commented 2 years ago

Closed in 74672627f822b51e9cd263167add41faf38e3550