Try to sort graphs numerically

Ticket:	#3942