Skip to content

Instantly share code, notes, and snippets.

@ErikHogenbirk
Created September 4, 2017 09:42
Show Gist options
  • Save ErikHogenbirk/98b5b9abed9896df1b0fbdb8fbd0ac7d to your computer and use it in GitHub Desktop.
Save ErikHogenbirk/98b5b9abed9896df1b0fbdb8fbd0ac7d to your computer and use it in GitHub Desktop.
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-18-6ad445ea486b> in <module>()
6 #'Proximity',
7 'TailCut',
----> 8 'TotalProperties'
9 ])
10 del bla
/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/minitrees.py in load(datasets, treemakers, preselection, force_reload, delayed, num_workers, compute_options, cache_file, remake_cache)
496
497 result = dask.dataframe.from_delayed(
--> 498 partial_results, meta=partial_results[0].compute())
499
500 if not delayed:
/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/dask/base.py in compute(self, **kwargs)
77 Extra keywords to forward to the scheduler ``get`` function.
78 """
---> 79 return compute(self, **kwargs)[0]
80
81 @classmethod
/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/dask/base.py in compute(*args, **kwargs)
177 dsk = merge(var.dask for var in variables)
178 keys = [var._keys() for var in variables]
--> 179 results = get(dsk, keys, **kwargs)
180
181 results_iter = iter(results)
/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/dask/threaded.py in get(dsk, result, cache, num_workers, **kwargs)
74 results = get_async(pool.apply_async, len(pool._pool), dsk, result,
75 cache=cache, get_id=_thread_get_id,
---> 76 **kwargs)
77
78 # Cleanup pools associated to dead threads
/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/dask/async.py in get_async(apply_async, num_workers, dsk, result, cache, get_id, raise_on_exception, rerun_exceptions_locally, callbacks, dumps, loads, **kwargs)
491 _execute_task(task, data) # Re-execute locally
492 else:
--> 493 raise(remote_exception(res, tb))
494 state['cache'][key] = res
495 finish_task(dsk, key, state, results, keyorder.get)
TypeError: ufunc subtract cannot use operands with types dtype('O') and dtype('<M8[s]')
Traceback
---------
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/dask/async.py", line 268, in execute_task
result = _execute_task(task, data)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/dask/async.py", line 249, in _execute_task
return func(*args2)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/dask/compatibility.py", line 47, in apply
return func(*args, **kwargs)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/minitrees.py", line 378, in load_single_dataset
run_id, treemaker, force_reload=force_reload, event_list=event_list)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/minitrees.py", line 325, in load_single_minitree
skimmed_data = treemaker().get_data(run_id, event_list=event_list)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/minitrees.py", line 92, in get_data
desc='Making %s minitree' % self.__class__.__name__)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/paxroot.py", line 165, in loop_over_datasets
for _ in function_results_datasets(*args, **kwargs):
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/paxroot.py", line 157, in function_results_datasets
raise e
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/paxroot.py", line 151, in function_results_datasets
yield event_function(event, **kwargs)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/minitrees.py", line 75, in process_event
result = self.extract_data(event)
File "/project/lgrandi/anaconda3/envs/pax_head/lib/python3.4/site-packages/hax-1.6.2-py3.4.egg/hax/treemakers/corrections.py", line 152, in extract_data
ts = ((self.run_start - np.datetime64('1970-01-01T00:00:00Z')) /
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment