Hi @Abhi, welcome to this Forum!
You might want to go through the following documentation pages:
https://distributed.dask.org/en/stable/serialization.html
https://distributed.dask.org/en/stable/protocol.html
In order to use some distributed or multi-process libraries like Dask, you need to send object and data back and forth between processes, which means serializing them. In order to serialize functions, Dask rely on pickle. Your objects need to be serializable if you want to use Dask distributed. You can check the serialization problem with some code snippet in Problems with object pickle - #6 by scharlottej13.