implemented onehotting