The reason Dooku was able to defeat Kenobi in ROTS was because Kenobi's force wall was lacking, making it easy for Dooku to slice through and rag doll Kenobi. The reason why he beat a more inexperienced Kenobi on Geonosis was because Dooku specialized in Form 2, Makashi, which was a precision dueling oriented form most Jedi were not trained to combat, while the reason why Anakin beat Dooku in ROTS was because while Makashi lacked strength, Djem So, Anakin's form was based on strength, making it easy to plow through Dooku's defense. The reason Anakin didn't beat Dooku on Geonosis was because at the time, he had specialized in the Shien variant of Djem So, a form geared for blaster fire. However, Kenobi wasn't just a specialist for Soresu, the all-defensive form. He was advanced in Ataru (the kinetic and acrobatic offense form) and Shien, while he held some proficiency for Niman (a form incorporating details from all other preceding forms) and Shii-Cho (the basic, straightforward form all Padawans learn. The reason he beat Anakin at the very end of ROTS was because he fought smarter, not harder, as well as Anakin's arrogance and anger clouding his judgement and while Kenobi's simple and effective Soresu form allowed him to use his energy more efficiently, Anakin had tired himself out using Djem So to his fullest extent.