af.features.Features crashes when its __del__ method is called
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 38/100
Direzione di ricerca
I punti di ingresso segnalati sono af.orb, Features.get_xpos(), Features.get_ypos() e Features.del; esegui innanzitutto il minimo esempio funzionante fornito su Windows con ArrayFire 3.8.0. Traccia il ciclo di vita dell’oggetto quando gli array delle posizioni escono dall’ambito, quindi verifica che l’eliminazione di features non causi più un arresto anomalo silenzioso e che il caso della posizione restituita continui a funzionare.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
When using a Features() object, arrayfire crashes silently when calling the object's __del__() method if the object's get_xpos() method has already been deleted (or has fallen out of scope).
Potentially due to a similar root case as mentioned in #169 (or due to the changes made as a result of this in commit a9031fb5e0db371bc88c958f0b8d43efd7fe8f45)
Running on Windows; using arrayfire 3.8.0.
Minimum working example:
import arrayfire as af
def get_feature_locations(features):
# Get x and y positions of features
x_pos = features.get_xpos()
y_pos = features.get_ypos()
# If this is uncommented, the code works as intended
# return x_pos, y_pos
img = af.randn(d0=500, d1=500)
features, descriptors = af.orb(img, threshold=1, max_features=10, num_levels=1)
feature_locations = get_feature_locations(features)
print("Before delete")
del features
print("After delete")
Which outputs:
Before delete
Uncommenting line 10 (return x_pos, y_pos) outputs:
Before delete
After delete
Thanks!
- Lingua principale
- Python
- Stelle
- 422
- Fork
- 63
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di arrayfire/arrayfire-python
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
arrayfire/arrayfire-python#271 ·
-
Unwrap phase function Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
arrayfire/arrayfire-python#270 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
arrayfire/arrayfire-python#269 ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 48/100
arrayfire/arrayfire-python#267 · 1 commento · 1 reazione ·
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
arrayfire/arrayfire-python#266 ·
Tutte le issue di arrayfire/arrayfire-python
Issue simili
-
Add: hunch Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
AbdelStark/awesome-typesafe#104 ·
-
enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
DiamondLightSource/dodal#2211 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
openml/openml-python#1749 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
sipyourdrink-ltd/bernstein#6191 ·