You have the base grounded, so the transistor can only be turned on with a negative voltage on the emitter. You didn't label the pin the emitter is connected to, but it still can't work because the Pi can't generate a negative voltage on any output (and then there wouldn't be an input to the Pi).The purpose of the transistor is to allow a low (ground) signal into the Raspberry Pi pin when the switch in the diagram closes the circuit.