Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

analysis trajectories crashes with "buffer source array is read-only" #7

Open
grandrea opened this issue Jan 18, 2022 · 0 comments
Open

Comments

@grandrea
Copy link

grandrea commented Jan 18, 2022

Hello,
Hello, I run_analysis_trajectories.py the run crashes at the step

AT.hdbscan_clustering(['EV_sum', 'XLs_sum'])

with:

All available fields:  ['MC_frame' 'rmf_frame_index' 'Total_Score' 'XLs_sum' 'XLs_psi_sum'
....
 'EV_sum' 'traj' 'rmf3_file' 'CR_sum' 'half']
Fields selected for HDBSCAN clustering:  ['EV_sum' 'XLs_sum' 'CR_sum']
joblib.externals.loky.process_executor._RemoteTraceback:
"""
Traceback (most recent call last):
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/joblib/externals/loky/process_executor.py", line 407, in _process_worker
    call_item = call_queue.get(block=True, timeout=timeout)
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/multiprocessing/queues.py", line 116, in get
    return _ForkingPickler.loads(res)
  File "sklearn/neighbors/_binary_tree.pxi", line 1057, in sklearn.neighbors._kd_tree.BinaryTree.__setstate__
  File "sklearn/neighbors/_binary_tree.pxi", line 999, in sklearn.neighbors._kd_tree.BinaryTree._update_memviews
  File "stringsource", line 658, in View.MemoryView.memoryview_cwrapper
  File "stringsource", line 349, in View.MemoryView.memoryview.__cinit__
ValueError: buffer source array is read-only
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "run_analysis_trajectories.py", line 52, in <module>
    AT.hdbscan_clustering(['EV_sum', 'XLs_sum', 'CR_sum'], min_cluster_size=200)
  File "/beegfs/scratch/graziadei/imp_40S/scripts_PMI_analysis/../PMI_analysis/pyext/src/analysis_trajectories.py", line 840, in hdbscan_clustering
    hdbsc = hdbscan.HDBSCAN(min_cluster_size=min_cluster_size,
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/hdbscan/hdbscan_.py", line 919, in fit
    self._min_spanning_tree) = hdbscan(X, **kwargs)
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/hdbscan/hdbscan_.py", line 610, in hdbscan
    (single_linkage_tree, result_min_span_tree) = memory.cache(
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/joblib/memory.py", line 349, in __call__
    return self.func(*args, **kwargs)
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/hdbscan/hdbscan_.py", line 275, in _hdbscan_boruvka_kdtree
    alg = KDTreeBoruvkaAlgorithm(tree, min_samples, metric=metric,
  File "hdbscan/_hdbscan_boruvka.pyx", line 392, in hdbscan._hdbscan_boruvka.KDTreeBoruvkaAlgorithm.__init__
  File "hdbscan/_hdbscan_boruvka.pyx", line 426, in hdbscan._hdbscan_boruvka.KDTreeBoruvkaAlgorithm._compute_bounds
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/joblib/parallel.py", line 1056, in __call__
    self.retrieve()
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/joblib/parallel.py", line 935, in retrieve
    self._output.extend(job.get(timeout=self.timeout))
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/site-packages/joblib/_parallel_backends.py", line 542, in wrap_future_result
    return future.result(timeout=timeout)
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/concurrent/futures/_base.py", line 444, in result
    return self.__get_result()
  File "/home/users/g/graziadei/anaconda3/envs/imp-215/lib/python3.8/concurrent/futures/_base.py", line 389, in __get_result
    raise self._exception
joblib.externals.loky.process_executor.BrokenProcessPool: A task has failed to un-serialize. Please ensure that the arguments of the function are all picklable.

Any clues on what may be causing this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant