Fixed transformation bug and updated the transformer