The Uffizi is probably the better choice of the two if your goal is to see great works of art. The displays are at eye level, and there are not works placed high up on the wall as they are at Pitti Palace. Many of the paintings at the Palace are great. It's just more difficult to properly view many of them due to the lighting and high placement.
On the other hand, if your goal is to see a beautifully decorated palace that hearkens to the period, the Pitti Palace would be preferable. This would also be preferable if one has not visited many other palaces, as it provides a glimpse into how a wealthy family might have lived during the past.
The Boboli gardens are a vast space that is also interesting to see, mainly due to the layout. The vegetation is interesting, though there is not an abundance of flowering plants. It's the design, with pathways, ponds, and fountains, and the sheer vastness, that are so worth seeing.
Also worth noting: the Uffizi is much more crowded than Pitti Palace. It can be difficult to view certain popular artworks without other people standing in front of them. This is not so common at the Palace.
As an art aficionado, by degrees, I would choose the Uffizi, but the Pitti Palace has some great artworks, too. Truly, you can not go wrong with either choice...