Preventing unnecessary file reloads

   335   2   1
User Avatar
Member
307 posts
Joined: 7月 2013
オフライン
I've got a file node in Copernicus that loads quite a heavy PSD using a filename that comes in from a TOP network ( `@shot` )

It works fine, but it reloads the PSD even when it's the exact same file as already loaded. We generate about 10k of images, and this PSD only changes after every 500 images. So that's 499x a 5 second reload that isn't unnecessary.

Currently trying some trickery with a python expression in dummy parameters that only set the real filename's value when it's different but it's quite unstable due to thread spaghetti. Caching doesn't work either since reloading happens before that regardless.

Any clues beside building my own loader using PIL?
Edited by Jonathan de Blok - 2026年9月28日 15:02:23
More code, less clicks.
User Avatar
Member
307 posts
Joined: 7月 2013
オフライン
For now I've made an HDA wrapper around the loader with a smart 'update' button that is pushed by a pre-render script. It sets the real loaders filename only when it's different from the current.. not pretty, and kills the easy previewing, but it works..
More code, less clicks.
User Avatar
スタッフ
626 posts
Joined: 5月 2014
オフライン
From your testing, does it seem like the reloading is happening because TOPs is invalidating the parameter too often, or due to an issues in the COP itself? E.g. if you just use a constant string value instead vs an expression.

I can see about setting up something similar on my end to repro if it seems like a TOPS/PDG expr issue. It's possible that it's flagging the expression and therefore parm/node as dirty too often, causing the reload.
  • Quick Links