Comments (18)
@Moomboh thank you very much for your in depth response.
Yes, please open a separate issue for this. I'd also be happy to get a PR in with your suggested improvement and we can discuss it directly there!
from pertpy.
Prior to installing pertpy, install Qt5 via brew (and follow the directions to add to path), restart terminal, then run:
pip install pyqt5 --config-settings --confirm-license= --verbose
Then pip install pertpy works
from pertpy.
@xinyuejohn you're using a M1 right? Got any idea?
from pertpy.
Note: conda install -c anaconda pyqt
will lead to a version below the one required by pertpy (5.5.12 < 5.5.17).
from pertpy.
Accidentally closed when trying to add additional issue:
Setting up developer environment as described here
At the make install
step I get
` • Installing pyqt5-qt5 (5.15.2): Failed
RuntimeError
Unable to find installation candidates for pyqt5-qt5 (5.15.2)
`
Installing pyqt5 separately as described above does not fix.
`make install
rm -fr build/
rm -fr dist/
rm -fr .eggs/
find . -name '.egg-info' -exec rm -fr {} +
find . -name '.egg' -exec rm -f {} +
find . -name '.pyc' -exec rm -f {} +
find . -name '.pyo' -exec rm -f {} +
find . -name '*~' -exec rm -f {} +
find . -name 'pycache' -exec rm -fr {} +
poetry install
Installing dependencies from lock file
Package operations: 51 installs, 0 updates, 0 removals
• Installing pyqt5-qt5 (5.15.2): Failed
RuntimeError
Unable to find installation candidates for pyqt5-qt5 (5.15.2)
at ~/miniforge3/envs/pertpy-distances/lib/python3.9/site-packages/poetry/installation/chooser.py:105 in choose_for
101│
102│ links.append(link)
103│
104│ if not links:
→ 105│ raise RuntimeError(f"Unable to find installation candidates for {package}")
106│
107│ # Get the best link
108│ chosen = max(links, key=lambda link: self._sort_key(package, link))
109│
make: *** [install] Error 1`
from pertpy.
pip install PyQt5-Qt5 ERROR: Could not find a version that satisfies the requirement PyQt5-Qt5 (from versions: none) ERROR: No matching distribution found for PyQt5-Qt5
Not sure where to go from here @Zethson -- we considered removing the requirement from our branch but we're not sure where it's coming from in the first place
from pertpy.
It's from ipykernel I think
from pertpy.
@xinyuejohn you're using a M1 right? Got any idea?
Sorry for the late reply. I am using Mac with intel i5.
from pertpy.
The problematic pyqt5
dependency is required by ete3
, see https://github.com/etetoolkit/ete/blob/master/setup.py#L81
It is required by pertpy
here, probably because ete3 depends on it. I believe for ipykernel
it is just an optional dependency.
from pertpy.
@Moomboh Indeed. ete3 requires it for plotting. So I'll need to make these dependencies optional urgh.
from pertpy.
If I did things correctly, ete3 and pyqt5 should now be optional dependencies. @tessadgreen can you please test the latest development branch?
from pertpy.
Apparently people are working on it etetoolkit/ete#656
from pertpy.
Installing from the latest development branch following the directions in the Contributor Guide works, and I'm seeing the 'ete3' warning on import. Nox runs successfully and I'm able to import pertpy into python.
Should note that the Qt5 brew install was system wide so it is available in the new environment for me/I don't know if it now works without that step.
from pertpy.
Can confirm that setting up dev environment according to the Contributor Guide also works for me on Apple Silicon.
I also have qt5
installed system wide via brew install qt5
which might be an requirement.
Though to get nox
to run I had to do:
poetry run pip install nox nox-poetry
poetry run nox
I also managed to get pertpy running including rtools support and ete3 running on Apple Silicon:
-
Install
qt5
via homebrew:brew install qt5
Make sure to add all the environment variables to your
~/.zshrc
as described at the end of the output of thebrew install
command then reload your shell:zsh
-
Create environment with mamba (conda should work as well, but I haven't tested it):
# environment.yaml name: pertpy-apple-silicon channels: - conda-forge dependencies: - python=3.9 - rpy2
mamba create -f environment.yaml -n pertpy-apple-silicon mamba activate pertpy-apple-silicon
-
Install
pyqt5
viapip
in conda enviroment:pip install pyqt5 --config-settings --confirm-license= --verbose
This needs to be compiled from sources so this might take quite a while
-
Install
ete3
viapip
:pip install ete3
-
Finally install
pertpy
nightly viapip
:pip install git+https://github.com/theislab/pertpy.git
(As of this writing nightly was at theislab/pertpy@3e6a702)
Now pertpy should be working fine and you should be able to use all features 🎉
import pertpy as pt
I still get the ete3 warning on import, but I think this is due to a bug in pertpy/tools/init.py#L10
There are faulty import paths getting masked by the catching of the ImportError
for the ete3 warning.
from pertpy.tools.coda._sccoda import Sccoda
works fine.
I think pertpy/tools/init.py#L10 should be instead:
try:
from pertpy.tools.coda._sccoda import Sccoda
from pertpy.tools.coda._tasccoda import Tasccoda
except ImportError as e:
if "ete3" in str(e):
print(
"[bold yellow]To use sccoda or tasccoda please install ete3 with `pip install ete3`"
)
else:
raise e
@Zethson should I open a separate issue for this?
from pertpy.
New brew install required by the _dialogue.py. The new linear programming solver requires system-wise ipopt install on Mac, which can be done with brew install ipopt
from pertpy.
New brew install required by the _dialogue.py. The new linear programming solver requires system-wise ipopt install on Mac, which can be done with
brew install ipopt
It should only be required if you try to run DIALOGUE though, right?
Also, ipopt
is on conda
from pertpy.
Oh, yes sorry this came up when trying to run Dialogue, the install was fine/didn't error and I just had the problem when I tried to run the multifactor PMD with the linear programming addition. I got the error ApplicationError: No executable found for solver 'ipopt'
and followed the directions here. Assumed that was the problem I was having but I'm going back through the log now and it looks like ipopt isn't a dependency/wasn't installed by pip and the brew was overkill. Sorry for the confusion!
from pertpy.
Yeah, I'll write up proper installation instructions soon, sorry.
from pertpy.
Related Issues (20)
- Add dataloader for sciplex-GxE
- Enable a way to save sccoda plots HOT 2
- Compute method for MLPClassifierSpace
- 0.7.0 release
- MLPClassifierSpace on papalexi_2021 fails with TypeError: cannot pickle 'weakref.ReferenceType' object HOT 6
- Pre-release CI arviz: ImportError: cannot import name 'gaussian' from 'scipy.signal' HOT 1
- encounting issues when running DIALOGUE
- SCGEN lack of examples
- Augur sklearn warning HOT 3
- `annotate_compounds` for combinations of drugs HOT 2
- Use __all__ for public interfaces
- Can not import pertpy HOT 1
- Expression prediction tutorial HOT 1
- Weird behavior of Sccoda HOT 22
- scgen test broken HOT 1
- Unable to import pertpy due to SymPy error HOT 4
- Can't import pertpy owing to NameError!!! HOT 6
- scCODA convergence issue for continous covairables HOT 2
- How to plot the 0 value during different comparisons? HOT 11
- How to use Pertpy after subsetting the cell types? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pertpy.