As pointed out in the comments one potential problem is the use of a single pull up resistor, (R1), for all the optocouplers. For correct operation each optocoupler should have a separate pull up resistor, (and they should not be all tied together, for example - remove the extra wire segment between each pin 1). In your original schematic if you were to trigger one optocoupler all the others would become disabled (to some degree but not guaranteed).
As for the base resistor, that determines the base current in the transistor according to (Vin - Vbe)/Rb in your case (3.3V - 0.7V) / 10k = 0.26mA. This base current is then multiplied by the gain of the transistor to give the collector current (max). A typical MPS2222A has a gain as low as 35 with low base current, so the collector current could potentially be as low as 9.1mA, that should be well enough to turn on the optocoupler, (the 20mA spec might be a max).
Another point from a comment is that the each I/O port could most likely sink enough current to turn on an optocoupler without even using the transistor. You would just connect each I/O pin directly to each pin 2 of the optocoupler, keep a 200 ohm pull up on each pin 1 but instead of using 5V use the main system's 3.3V at the top of each resistor. In this case the optocoupler LED current would be about 10.5mA, and the logic would be reversed, (a low on the I/O pin turns on the optocoupler).
Also note that you will need to have a power and load connected to the output pins of the optocoupler to verify the switching action. (Your schematic does not show what is connected at those points.) Unlike a mechanical relay you cannot normally measure the on/off switching with just a DVM placed on the open pins.