It's not idiomatic to say I've took the liberty. Instead, it's either I've taken the liberty or I took the liberty. The last part of the sentence can be either of doing or to do.
As such, there are four possible variations, all of which sound natural:
I've taken the liberty of doing it.
I've taken the liberty to do it.
I took the liberty of doing it.
I took the liberty to do it.
Which of those four should be used is a matter of style and personal choice.
All four versions could also be expressed with a single variation that doesn't include the taking of liberty:
I went ahead and did it.