rsinghlab / pyaging Goto Github PK
View Code? Open in Web Editor NEWA Python-based compendium of GPU-optimized aging clocks.
Home Page: https://pyaging.readthedocs.io
License: BSD 3-Clause "New" or "Revised" License
A Python-based compendium of GPU-optimized aging clocks.
Home Page: https://pyaging.readthedocs.io
License: BSD 3-Clause "New" or "Revised" License
pyaging==0.1.5, python==3.9
adata = pya.pred.predict_age(adata, ['Horvath2013', 'AltumAge', 'PCGrimAge', 'dnamtl', ])
_|-----> ποΈ Starting predict_age function
|-----> βοΈ Set PyTorch device started
|-----------> Using device: cuda
|-----> β
Set PyTorch device finished [0.8091s]
|-----> π Processing clock: horvath2013
|-----------> βοΈ Load clock started
|-----------------> Data found in pyaging_data/horvath2013.pt
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
Cell In[6], line 1
----> 1 adata = pya.pred.predict_age(adata, ['Horvath2013', 'AltumAge', 'PCGrimAge', 'dnamtl', ])
File ~/anaconda3/envs/pyaging/lib/python3.9/site-packages/pyaging/predict/_pred.py:81, in predict_age(adata, clock_names, dir, verbose)
78 logger.info(f"π Processing clock: {clock_name}", indent_level=1)
80 # Load and prepare the clock
---> 81 model = load_clock(clock_name, device, dir, logger, indent_level=2)
83 # Check and update adata for missing features
84 check_features_in_adata(
85 adata,
86 model,
87 logger,
88 indent_level=2,
89 )
File ~/anaconda3/envs/pyaging/lib/python3.9/site-packages/pyaging/utils/_utils.py:72, in progress.<locals>.decorator.<locals>.wrapper(*args, **kwargs)
70 logger = args[-1] # Assumes logger is the last positional argument
71 logger.start_progress(f"{message} started", indent_level=indent_level)
---> 72 result = func(*args, **kwargs)
73 logger.finish_progress(f"{message} finished", indent_level=indent_level)
74 return result
File ~/anaconda3/envs/pyaging/lib/python3.9/site-packages/pyaging/predict/_pred_utils.py:92, in load_clock(clock_name, device, dir, logger, indent_level)
89 clock = torch.load(weights_path)
91 # Prepare clock for inference
---> 92 clock.to(torch.float64)
93 clock.to(device)
94 clock.eval()
AttributeError: 'dict' object has no attribute 'to'_
Hello, I used Pyaging=0.3.6, but I could not install the package. I tried three methods in the help documentation, and all errors occurred:
AttributeError: 'NoneType' object has no attribute 'split'
I guess the reason is that the dependency package pybigwig package cannot be installed. Is there any solution? I use windows system
The error is as follows:
(Pyaging) C:\Users\admin>pip install Pyaging
Looking in indexes: https://mirrors.aliyun.com/pypi/simple/
Collecting Pyaging
Using cached https://mirrors.aliyun.com/pypi/packages/46/b3/f573c6c7ca1f349503da8e6bc31f9e9b3bc0f9cd1a926cfefff2ac38edd0/pyaging-0.1.6-py3-none-any.whl (37 kB)
Requirement already satisfied: anndata<0.11.0,>=0.10.3 in c:\users\admin\anaconda3\envs\pyaging\lib\site-packages (from Pyaging) (0.10.5.post1)
Requirement already satisfied: numpy<2.0.0,>=1.26.2 in c:\users\admin\anaconda3\envs\pyaging\lib\site-packages (from Pyaging) (1.26.4)
Requirement already satisfied: pandas<3.0.0,>=2.1.3 in c:\users\admin\anaconda3\envs\pyaging\lib\site-packages (from Pyaging) (2.2.1)
Collecting pyBigWig<0.4.0,>=0.3.22 (from Pyaging)
Using cached https://mirrors.aliyun.com/pypi/packages/f0/57/334db9a75d6941876ef282cc7eb1885a24fe71d3c6522c19f717db4f8b73/pyBigWig-0.3.22.tar.gz (73 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
Γ Getting requirements to build wheel did not run successfully.
β exit code: 1
β°β> [15 lines of output]
Traceback (most recent call last):
File "C:\Users\admin\anaconda3\envs\Pyaging\lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 353, in
main()
File "C:\Users\admin\anaconda3\envs\Pyaging\lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "C:\Users\admin\anaconda3\envs\Pyaging\lib\site-packages\pip_vendor\pyproject_hooks_in_process_in_process.py", line 118, in get_requires_for_build_wheel
return hook(config_settings)
File "C:\Users\admin\AppData\Local\Temp\pip-build-env-g85iu5lr\overlay\Lib\site-packages\setuptools\build_meta.py", line 325, in get_requires_for_build_wheel
return self._get_build_requires(config_settings, requirements=['wheel'])
File "C:\Users\admin\AppData\Local\Temp\pip-build-env-g85iu5lr\overlay\Lib\site-packages\setuptools\build_meta.py", line 295, in _get_build_requires
self.run_setup()
File "C:\Users\admin\AppData\Local\Temp\pip-build-env-g85iu5lr\overlay\Lib\site-packages\setuptools\build_meta.py", line 311, in run_setup
exec(code, locals())
File "", line 19, in
AttributeError: 'NoneType' object has no attribute 'split'
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
Γ Getting requirements to build wheel did not run successfully.
β exit code: 1
β°β> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
ThankyouοΌοΌ
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.