Did the members of the 501st know, at that time, that Anakin had become a Sith Lord and was now Darth Vader?
It is tempting to say that the answer is obviously "yes", because why else would a Jedi attack the Jedi Temple? However, answers to related questions note that it was publicly believed that Anakin had died in the Jedi Temple defending Jedi children and, furthermore, even high-ranking members of the Imperial military -- such as Moff Tarkin -- did not know with certainty that Anakin was Vader. Obviously, the 501st knew that Anakin helped them attack -- not defend -- the Jedi Temple, and they probably knew he was very much alive at the end of the attack. Moreover, if the 501st knew Vader's true identity, then they must have kept that fact from high-ranking Imperial officers since those officers did not know Vader's true identity. It would be a truly impressive display of operational security if an entire legion of troops managed to hide Vader's identity from even Imperial officers. This is only plausible because the 501st is composed of highly trained and professional soldiers who also happen to be clones bred for obedience.
It is difficult to explain what happened if the answer is "no", too, though. In that case, the 501st was presumably told that all the Jedi were traitors but that Anakin had defected from the Jedi. Since Anakin had previously commanded the 501st in the Clone Wars, it made sense that he would lead them in the attack. But that still doesn't explain how the 501st were led to believe that Anakin died in the Jedi Temple -- he'd have to somehow duck out in the middle of the battle, fake his death, and then explain how not a single clone in the Temple found his corpse.
Is there a source which definitively answers whether the 501st knew Anakin was Darth Vader during the attack on the Jedi Temple? For example, a source which includes a quote of Anakin calling himself Vader in the Jedi Temple and in the presence of clones from the 501st would prove that the 501st knew his true identity; on the other hand, a source which includes a quote of a 501st clone referring to Vader as Anakin would indicate that the 501st did not know the two were the same man.
Canon answers are preferred, although Legends answers are acceptable if canon is silent on the issue.