diff --git a/ess/SP_Relativity.py b/ess/SP_Relativity.py
index beeafe3bf62e18cbfb1c35b81cdc8fe3a6b59148..5c87cbe16d7be3f981bed0e2d7d6f0ccff5424bc 100644
--- a/ess/SP_Relativity.py
+++ b/ess/SP_Relativity.py
@@ -141,6 +141,7 @@ def emit_geo(u_up_array):
     -------
     geometrical emittance of the distribution/array in units of pi.mm.mrad
     '''
+    import numpy as np
     u_shift = u_up_array[:,0]      #  x
     up_shift = u_up_array[:,1]     #  x'
     u = u_shift - np.average(u_shift)