We are using Google Cloud to run a cluster of VMs for parallel video processing with FFmpeg. Each VM contains a container running Dask. The worker directory of the container is an NFS file system shared among all the Dask workers and the scheduler.
Inside the worker i get this:
2024-09-11 18:15:39,018 - root - WARNING - Plugin registered successfully.
/data/superresolution/src/workers/superresolution_dask.py:795: DeprecationWarning: `Client.register_worker_plugin` has been deprecated; please use `Client.register_plugin` instead
client.register_worker_plugin(CustomModulePlugin())
2024-09-11 18:15:39,020 - root - WARNING - Splitting video into pieces...
--- Logging error ---
Traceback (most recent call last):
File "/usr/local/lib/python3.10/logging/__init__.py", line 1100, in emit
msg = self.format(record)
File "/usr/local/lib/python3.10/logging/__init__.py", line 943, in format
return fmt.format(record)
File "/usr/local/lib/python3.10/logging/__init__.py", line 678, in format
record.message = record.getMessage()
File "/usr/local/lib/python3.10/logging/__init__.py", line 368, in getMessage
msg = msg % self.args
TypeError: not all arguments converted during string formatting
Call stack:
File "/usr/local/lib/python3.10/threading.py", line 973, in _bootstrap
self._bootstrap_inner()
File "/usr/local/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
self.run()
File "/usr/local/lib/python3.10/threading.py", line 953, in run
self._target(*self._args, **self._kwargs)
File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 83, in _worker
work_item.run()
File "/usr/local/lib/python3.10/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.10/site-packages/distributed/client.py", line 409, in execute_callback
fn(fut)
File "/data/superresolution/src/workers/superresolution_dask.py", line 288, in check_future
logging.error("Error logging command:", f.exception())
Message: 'Error logging command:'
Arguments: (RuntimeError('Error during deserialization of the task graph. This frequently\noccurs if the Scheduler and Client have different environments.\nFor more information, see\nhttps://docs.dask.org/en/stable/deployment-considerations.html#consistent-software-environments\n'),)
Inside the scheduler i get the “No module named ‘my_module’”
startup-script: Dask client initialized.
startup-script: Executing command: /usr/bin/ffmpeg7.0.1/bin/ffmpeg -i SD/pillarbox/video.mxf -ss 0.0 -to 60.027 -c copy -map 0:v -map 0:a -y temp_segments/segment_000.mxf
startup-script: graph = deserialize(graph_header, graph_frames).data
startup-script: File \"/usr/local/lib/python3.10/site-packages/distributed/protocol/serialize.py\", line 449, in deserialize
startup-script: return loads(header, frames)
startup-script: File \"/usr/local/lib/python3.10/site-packages/distributed/protocol/serialize.py\", line 111, in pickle_loads
startup-script: return pickle.loads(pik, buffers=buffers)
startup-script: File \"/usr/local/lib/python3.10/site-packages/distributed/protocol/pickle.py\", line 96, in loads
startup-script: return pickle.loads(x)
startup-script: ModuleNotFoundError: No module named 'my_module'
Given this setup, any insights on what might be causing this?