Hearts had gone into the game on a high following their League Cup quarter-final win over Hibernian but goals in each half from Nigel Hasselbaink and Stevie May saw them fail to cut the 15-point deficit at the bottom of the Scottish Premiership.
Hearts started brightly but Hasselbaink missed good chances either side of his 28th-minute opener when he headed home following a one-two with Chris Millar after Dylan McGowan had lost the ball deep inside his own half.
St Johnstone came out determined to finish off the job after half-time and Gary McDonald forced two good saves from Jamie MacDonald and David Wotherspoon had two efforts cleared off the line before May curled home from 15 yards in the 53rd minute.
Tynecastle was unusually flat after that goal and Hearts never looked like making a comeback, although they created sporadic pressure from set-pieces.
Locke has been generally happy with his team's approach this season, apart from conceding soft goals, and was not too hard on his players after below-par displays in crucial defeats against St Mirren and Kilmarnock.
But, after praising them for their derby heroics days earlier, he gave them a post-match dressing down after they stretched their recent run to one point from a possible 24.
"The first half I thought we did okay but the start of the second half, and I have just told the players, it was unacceptable," Locke told Hearts TV.
"We might be a young team but we have got to do a hell of a lot better than that in terms of the desire to stop crosses coming in. The two goals we lost were really, really poor and we have got to do a lot better.
"At half-time we were trying to get their heads up and get them going. But they have got to go out on the pitch and get themselves going at times as well.
"We can't keep trying to get them going at the sidelines all the time, they have got to do a bit themselves.
"We didn't start the second half well and we owe it to the supporters to put in a far, far better performance because we showed on Wednesday what we are capable of and for some reason we go out and looked a shadow of the team that played on Wednesday night."
Hearts next face a difficult trip to Aberdeen and Locke has demanded major improvement.
"We owe it to the supporters," he said.
"Very rarely this season have I had to have a go at the players because they have given us everything but certainly the start of the second half is something I'm not going to accept."