0

I have the following

from astropy import units as u
from astropy.modeling.models import BlackBody

bb = BlackBody(temperature=303.15*u.K)
wav = np.arange(1.0, 50.0) * u.micron
flux = bb(wav)

where flux has units:

 erg / (cm2 Hz s sr)

I'd like to convert these to:

 W / (m2 sr Hz)

but simply doing

flux.si 

gives flux but with 10^-3 values and units of kg / (rad2 s2).

Iguananaut
  • 21,810
  • 5
  • 50
  • 63
npross
  • 1,756
  • 6
  • 19
  • 38

1 Answers1

0
flux.to(u.W/u.m**2/u.steradian/u.Hz)

seems to do the trick nicely.

npross
  • 1,756
  • 6
  • 19
  • 38