Commit 6e6195969cf5395ec143704f21e64954e5bfbfca

Authored by knodlseder
1 parent 5d99317b

delete sim after usage (does not solve Python memory problems)

Showing 1 changed file with 3 additions and 0 deletions
scripts/obsutils.py
... ... @@ -116,6 +116,9 @@ def sim(obs, log=False, debug=True, seed=0, nbins=0, binsz=0.05, npix=200):
116 116 # (the ctobssim object will go out of scope one the function is
117 117 # left)
118 118 obs = sim.obs().copy()
  119 +
  120 + # Delete the simulation
  121 + del sim
119 122  
120 123 # Return observation container
121 124 return obs
... ...