question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Install issues on POWER, aka, make mostly-unsued dependencies optional

See original GitHub issue

🐛 Bug

Many of pytorch_geometric’s dependencies are entirely optional for the core library. Searching the codebase seems to indicate that the only “core” dependencies (those that are used anywhere except in a specific dataset or single transform) are

install_requires = [
    'numpy',
    'tqdm',
    'scipy',
    'networkx',
    'jinja2',
]

It would be nice if the other dependencies are specified as one or more extras_require sections, such as a datasets and transforms extras, for example. (Unfortunately, there does not appear to be a way to specify a default set of extras — see here — so the installation instructions would have to be updated correspondingly.) Alternatively, dependencies that are only used for specific datasets can just be wrapped in

try:
   
except ImportError:
    raise "useful message"

guards so that only users who need those dependencies will install them.

This is related to a specific bug: while trying to install pytorch_geometric on a ppc64 architecture cluster, we ran into issues related to the llvmlite dependency of numba, which is a pytorch_geometric dependency. numba is only used in the GDC transform. By commenting out numba in setup.py and its import in gdc.py, we were able to install and import pytorch_geometric.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
simonbatznercommented, Apr 21, 2021

Vielen Dank Matthias! 😃

1reaction
rusty1scommented, Apr 21, 2021

Should be fixed as well.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Throws error for unused optional peer dependencies #1560
Describe the bug Fresh install of RNUILib, Expo v4.0.15. When importing throws errors that an optional peer dependency is missing.
Read more >
How to Remove Unused Dependencies in React - Pluralsight
You will mostly need to run this command in the root directory of your project. Thus, depcheck separates the list of unused dependencies...
Read more >
systemctl - Freedesktop.org
To show all installed unit files use 'systemctl list-unit-files'. ... Units which are not active and are not in a failed state usually...
Read more >
How I can skip installing optional dependencies by 'npm ci'?
You can use npm ci --no-optional . If npm still installs the optional package. Then try after removing package.lock.json and run the command ......
Read more >
How to Check if You Have Unused Dependencies in Your ...
Solution 1. depcheck ; npm install -g depcheck. Second, launch the dependency analyzer simply by: ; depcheck. Third, check the unused dependencies ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found