Hi,
have you been able to solve the problem with low performance when using a custom connected layers? I am trying to do something similar but I am afraid that if I have used dense layers with masks, I would not be able to fit the model into the GPU’s memory.