First you need a plane, then emit some particles from that plane. Make sure that the particles have the rgbPP attribute available as we will need to put an expression on it.
Create a SOuP TextureToArray node
Create a SOuP rgbaToColorAndAlpha node
Create two ramp texture nodes - ramp1 is black to red along U, ramp two is black to green along V
Connect the following:
ramp2.outColor --> ramp1.colorOffset
ramp1.outColor --> textureToArray1.inColor
polyPlaneShape.worldMesh --> nParticleShape.inputGeometry
polyPlaneShape.worldMesh --> textureToArray1.inGeometry
textureToArray1.outRgbaPP --> rgbToColorAndAlpha1.inRgbaPP
Also connect the emitting plane's transform node to the particle's transform node as shown in the node graph.
Now set the rgbPP using the creation expression:
Rewind and step forward one frame so that the particles are emitted. Then set their initial state and disconnect the emitter and the connection between polyPlaneShape.worldMesh --> nParticleShape.inputGeometry
The particles will now be dynamic again.
In Nuke, plug in your rendered particles into the STMap node as shown in the image below