I removed this from a floor several years ago. Lucky for me I had someone in the flooring and reno business to advise me. It worked like a charm...a little elbow grease...and viola`
VERY VERY HOT water...soak (bucketful) the CARPET (as in NOT removed)....take a long handled scraper (the kind you use to remove tiles from a floor - you stand up to use it - much easier on knees!)...repeat as required. Any remaining bits and pieces are easy to remove as well. The subfloor dries reasonably soon without damage.
I'm not sure of the effect on a wood floor, though.