If the quantity starts with 'power'
then x is returned unchanged.
And if the type of x is 'material' or 'responsivity.material'
then x is returned unchanged.
Otherwise, the quantity starts with 'photons'
so the quantity of x is actinometric (proportional to number of photons/sec).
If the type is 'light' then
the most common actinometric unit of photon flux is ($\mu$mole of photons)/sec.
The conversion equation is:
$$p = x * (10^{-6} * N_A * h * c / \lambda)$$
where $p$ is proportional to the power of photons,
$x$ is the photon flux,
$N_A$ is Avogadro's constant,
$h$ is Planck's constant, $c$ is the speed of light,
and $\lambda$ is the wavelength in meters.
The output power unit is watts.
If the unit of x is not ($\mu$mole of photons)/sec,
then the output should be scaled appropriately.
For example, if the photon flux is exaphotons/sec,
then divide the output by 0.6022.
If the type is 'responsivity.light',
then the most common actinometric unit of responsivity to light is quantum efficiency (QE).
The conversion equation is:
$$r = x * \lambda * e / (h * c)$$
where $r$ is the responsivity,
$x$ is the quantum efficiency,
and $e$ is the charge of an electron (in C).
The output responsivity unit is amps/watt (A/W) or coulombs/joule (C/J).
If the unit of x is not quantum efficiency,
then the output should be scaled appropriately.