It's essentially a flow calculation. Be sure to use the valve's capacity, not the required relieving capacity used to size the valve.
If it's a liquid, it's relatively straightforward. You determine the outlet piping system and the components in it and convert that to equivalent feet. What is the pressure where the PSV outlet line is discharging to (if not atmospheric) and therefore, what inlet pressure (eg. PSV outlet) you need to get that flow rate through the line.
If it's a gas, you'll likely need to do a compressible flow calculation using the same approach as above. You might get away with an incompressible flow calculation IF the pressure drop through the PSV outlet line is small enough (less than about 10% of the absolute inlet pressure).
If it's 2 phase flow, it's more difficult, a lot more difficult.
There are lots of other considerations to what I've gone through here, you need to look at your entire system to decide what needs to be calculated or verified and what can be taken as a 'constant'. In some cases the back pressure in a flare system is taken as a constant number, in other cases, you need to calculate it. It depends on the case being considered.