Outgoing Presidents still work towards the future electability of other members of their party over the alternatives - in Obama's case, Clinton or Sanders over the Republicans. That's part of the opportunism, along with, yes, saving the more controversial unilateral actions for when they no longer need to worry about their own re-election or cooperation from Congress.
Liberal Democrats can then feel better (via recency bias) about a party that continued the Patriot Act, Gitmo, whistleblower prosecution, etc ad nauseam, while the next candidate can appeal to the moderate right that "hey, that was the last guy."
My point though was that it would be a misconception that an outgoing second term President doesn't have to weigh the impact of their decisions on future elections, even if they themselves will never run in one again. They aren't truly free to just drop whatever policies they want with no consideration for how it will impact future elections.
This one is getting done precisely because it can work with that agenda, unlike other possible policies that I'd bet, deep down inside, he has to know would also be good for the country - e.g. rescheduling marijuana or ending the war on drugs - but that would have a larger negative impact on future Democratic candidates.
The election cycle does have something to do with it: in the last year of his presidency, he has nothing to lose legislatively by putting all his proposals on the table. In previous years, he had to weigh each of them against the cost of losing whatever he was trying to accomplish with Congress.
That's not Obama's fault; it's the nature of the system. The President can't do whatever they want; their hands are tied by the other two branches of government. Blame John Adams.