You can't go wrong as long as people see you're trying
but the more you practice, the more you get the hang of it and how people address each other. From my experience though, Sensei is always the dojo cho, also i would address a Shihan with Sensei, if needed, which rarely happens. Like someone already said though half joking umm think if you are high enough to address the Shihan. I know i wouldn't talk to one unless i am spoken to. As far senior mudansha, i think it also depends on how well you know the person, age difference, rank difference, what kind of person are they - so when you take all of that into careful consideration, you can just call them by first name
when they teach class would be a lil different, so again consider everything mentioned above and then whatever you call them, don’t forget to bow...
This is my code and i stand by it! worked fine so far
when i get thrown out of a dojo, i will come back and edit this post..