Skip to content

Commit

Permalink
Allow default number of nb_workers to be configured with "None".
Browse files Browse the repository at this point in the history
  • Loading branch information
shermansiu committed Apr 27, 2024
1 parent 261a652 commit b00dfd1
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pandarallel/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -453,11 +453,14 @@ class pandarallel:
def initialize(
cls,
shm_size_mb=None,
nb_workers=NB_PHYSICAL_CORES,
nb_workers: Optional[int] = None,
progress_bar=False,
verbose=2,
use_memory_fs: Optional[bool] = None,
) -> None:
if nb_workers is None:
nb_workers = NB_PHYSICAL_CORES

show_progress_bars = progress_bar
is_memory_fs_available = Path(MEMORY_FS_ROOT).exists()

Expand Down

0 comments on commit b00dfd1

Please sign in to comment.