Edge case for processing 1 file when >1 workers are provided
@pweigel ci sta già lavorando.
Dal 25/11/2024.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
Describe the bug
There seems to be a weird edge case when processing single file "datasets" using more than one worker. I guess this is because https://github.com/graphnet-team/graphnet/blob/65ec11c8ee5f5b8448343a2254df9d6a9bc6187c/src/graphnet/data/dataconverter.py#L277-L293 is setting n_workers = 1 when there is one file and does not use multiprocessing, but https://github.com/graphnet-team/graphnet/blob/65ec11c8ee5f5b8448343a2254df9d6a9bc6187c/src/graphnet/data/dataconverter.py#L259-L263 uses self._num_workers and tries to access the global variables that are used for multiprocessing.
To Reproduce
Steps to reproduce the behavior:
- Process i3 files using >1 workers and only one file in the input folder
Expected behavior
It should allocate just one worker and be processed normally.
Full traceback
File "<path>/graphnet/src/graphnet/data/dataconverter.py", line 260, in _request_event_nos
with global_index.get_lock(): # type: ignore[name-defined]
^^^^^^^^^^^^
NameError: name 'global_index' is not defined. Did you mean: 'init_global_index'?
- Lingua principale
- Python
- Stelle
- 117
- Fork
- 115
- Merge medio
- 2g 21h
- PR unite (30g)
- 1
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Nessuna guida per i contributori
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 graphnet-team/graphnet
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
graphnet-team/graphnet#933 ·
-
Spring cleanAperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
graphnet-team/graphnet#927 · 1 commento ·
-
Time for a new version release v1.8.1Forse di nuovo libera @Aske-Rosted l’ha presa 75 giorni fa e non c’è nessuna pull request aperta. Apertadecision
graphnet-team/graphnet#924 · 1 assegnatario ·
-
Make kaggle checkpoints part of the CIForse di nuovo libera @sevmag l’ha presa 75 giorni fa e non c’è nessuna pull request aperta. Apertabug
graphnet-team/graphnet#921 · 2 commenti · 1 assegnatario ·
-
decision deferred
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
graphnet-team/graphnet#919 ·
Tutte le issue di graphnet-team/graphnet
Issue simili
-
MarkdownDocSerializer.post_process escapes '\<' to '\<', rendering literal '<' in CommonMarkAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
docling-project/docling-core#1067 ·
I maintainer di solito rispondono entro 3 giorni
-
correction metadata
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 85/100
acl-org/acl-anthology#11101 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[BUG] crewai tool create/install/login exit 0 when they failForse già presa @Kiko0301 l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
vllm-project/compressed-tensors#1033 ·
I maintainer di solito rispondono entro 3 giorni
-
chore kaizen ui-rewrite
Difficoltà 2/5 1-3 ore Idoneità per principianti 64/100
IBM/mcp-context-forge#7681 ·
I maintainer di solito rispondono entro 2 giorni