`n_jobs` not passed to `'auto'` learners in `SparseLinearDML()`
Nobody has claimed this yet.
- Dominant language
- Jupyter Notebook
- Stars
- 4.8k
- Forks
- 827
- PR merge metrics
- No merged PRs in 30d
Description
When fitting a SparseLinearDML model, one can pass an n_jobs argument to the constructor to specify the number of cores used when fitting. However, this only applies to the LASSO second stage. When using the default 'auto' first stage model selector, the n_jobs argument is not passed to the first stage. This yields the unfortunate consequence of fitting random forests for both the treatment propensity and outcome models with only one CPU core enabled if the default auto first stage model selector is used.
This presumably is also an issue for the DML parent class.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the SparseLinearDML implementation and trace how its default 'auto' first-stage selector is constructed, then compare that path with the DML parent class and the LASSO second stage. Confirm that n_jobs reaches the random-forest treatment and outcome models, and add or update regression coverage showing the configured core count is used.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- machine-learning
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100