Hy kal,
Nice bit of development engineering. You are dead right: the 1K resistor will be dissipating 510mW, as you say. That is not an awful lot but for production I would advise a 1W resistor or above.
You would not want to increase the resistor value to 2K2, because, although that will reduce the dissipation, it will not establish sufficient current in the optocoupler LED.
Unless you get hold of a 1K, 1W or above resistor, your best bet would be to put two 0.5W, 470 Ohm resistors in series or a couple 0.5W, 2K2 resistors in parallel.
Cheers
spec