How to access neighbor nodes and elements (fenicsx)

Your question is quite vague, please follow the guidelines of Read before posting: How do I get my question answered?
Please also refer to the previous posts,

and explain what is not working with them for your application.