functions implementation in DiffusionNetWork class