---------------------------------------------------------------------------
NameError Traceback (most recent call last)
<ipython-input-5-5fa805d04ebd> in <module>()
----> 1 get_ipython().run_cell_magic(u'time', u'', u'level = 7\nNSIDE=2**level\nnmax = hp.nside2npix(NSIDE)\ngaia.add_variable("healpix_scaling", 34359738368*4**(12-level))\nc=gaia.count(binby="source_id/healpix_scaling", limits=[0., nmax], shape=nmax)#, selection="phot_g_mean_mag < 26")')
/Users/users/breddels/.local/lib/python2.7/site-packages/IPython/core/interactiveshell.pyc in run_cell_magic(self, magic_name, line, cell)
2118 magic_arg_s = self.var_expand(line, stack_depth)
2119 with self.builtin_trap:
-> 2120 result = fn(magic_arg_s, cell)
2121 return result
2122
<decorator-gen-60> in time(self, line, cell, local_ns)
/Users/users/breddels/.local/lib/python2.7/site-packages/IPython/core/magic.pyc in <lambda>(f, *a, **k)
191 # but it's overkill for just that one bit of state.
192 def magic_deco(arg):
--> 193 call = lambda f, *a, **k: f(*a, **k)
194
195 if callable(arg):
/Users/users/breddels/.local/lib/python2.7/site-packages/IPython/core/magics/execution.pyc in time(self, line, cell, local_ns)
1175 else:
1176 st = clock2()
-> 1177 exec(code, glob, local_ns)
1178 end = clock2()
1179 out = None
<timed exec> in <module>()
/Users/users/breddels/src/vaex/vaex/dataset.pyc in count(self, expression, binby, limits, shape, selection, async)
2356 stats = [calculate(expression, limits) for expression in expressions]
2357 var = finish(*stats)
-> 2358 return self._async(async, var)
2359
2360 @docsubst
/Users/users/breddels/src/vaex/vaex/dataset.pyc in _async(self, async, task, progressbar)
2930 return task
2931 else:
-> 2932 self.executor.execute()
2933 return task.get()
2934
/Users/users/breddels/src/vaex/vaex/execution.pyc in execute(self)
151 task._results = []
152 task.signal_progress.emit(0)
--> 153 block_scopes = [dataset._block_scope(0, self.buffer_size) for i in range(self.thread_pool.nthreads)]
154 def process(thread_index, i1, i2):
155 if not cancelled[0]:
/Users/users/breddels/src/vaex/vaex/dataset.pyc in _block_scope(self, i1, i2)
4388
4389 def _block_scope(self, i1, i2):
-> 4390 variables = {key:self.evaluate_variable(key) for key in self.variables.keys()}
4391 return _BlockScope(self, i1, i2, **variables)
4392
/Users/users/breddels/src/vaex/vaex/dataset.pyc in <dictcomp>((key,))
4388
4389 def _block_scope(self, i1, i2):
-> 4390 variables = {key:self.evaluate_variable(key) for key in self.variables.keys()}
4391 return _BlockScope(self, i1, i2, **variables)
4392
/Users/users/breddels/src/vaex/vaex/dataset.pyc in evaluate_variable(self, name)
4348 if isinstance(self.variables[name], six.string_types):
4349 # TODO: this does not allow more than one level deep variable, like a depends on b, b on c, c is a const
-> 4350 value = eval(self.variables[name], expression_namespace, self.variables)
4351 return value
4352 else:
<string> in <module>()
NameError: name 'source_id' is not defined