Barry returned from the Speed Force on the season 4 premiere of The Flash. But when Iris and the gang met up with him they realized something wasn't quite right.
Barry was suffered from schizophasia, which Caitlin described as "where you assign the wrong definitions to words."
To make matters worse, there was a new bad guy that was threatening to destroy the city unless he could fight the Flash.
In order to snap Barry out of his funk, Iris let the samurai take her hostage so that the Flash would have to save her. And her plan worked perfectly.
Upon learning of her situation, Barry through on his Flash suit and quickly defeated the samurai, which turned out to be a robot.
Apparently the whole ordeal was a clever ruse by what may be the season 4 archvillain, The Thinker. We don't know much about The Thinker, but for right now fans are just glad Barry is fighting yet another speedster.