arrayfire / arrayfire/arrayfire-python
backends do not load in proper order
- Langage dominant
- Python
- Étoiles
- 422
- Forks
- 63
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
[This line](https://github.com/arrayfire/arrayfire-python/blob/28a0f610c5329ebc718ce4d924f870c3651bfb3e/arrayfire/library.py#L646) has a comment `# Iterate in reverse order of preference`. However, it loads them with some random order, because the object to iterate is a `set`, which doesn't keep the order. In my Linux computer, when I run `import arrayfire as af`, the function will be called and it loads `""` first, and due to `err!=0`, it directly returns and not loads anything.
By the way, I simply change `{"cpu", "opencl", "cuda", ""}` to `["cuda"]` and I can import arrayfire with no error.
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Piste de recherche
Start at library.py line 646, where backend loading iterates over the listed backends, and inspect the import path triggered by `import arrayfire as af`. Verify that backend loading follows the documented preference order and that importing ArrayFire no longer returns early without loading a backend.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- python
- Domaine
- backend
- Type d'issue
- Bug
- Difficulté
- 2/5
- Temps estimé
- 1-3 heures
- Activité
- À l'abandon
- Clarté
- Clairement spécifiée
- Accessibilité débutants
- 35/100