causalml icon indicating copy to clipboard operation
causalml copied to clipboard

Fixing Anaconda Install environment-py38.yml

Open DanielDaCosta opened this issue 3 years ago • 3 comments

Proposed changes

Fixing the following error that shows up when we try to create a conda environment from environment-py38.yml:

The conflict is caused by:
    The user requested numpy==1.20.3
    h5py 2.10.0 depends on numpy>=1.7
    lightgbm 3.2.1 depends on numpy
    matplotlib 3.4.1 depends on numpy>=1.16
    numba 0.53.1 depends on numpy>=1.15
    opt-einsum 3.3.0 depends on numpy>=1.7
    pandas 1.2.4 depends on numpy>=1.16.5
    patsy 0.5.1 depends on numpy>=1.4
    pygam 0.8.0 depends on numpy
    pyro-ppl 1.6.0 depends on numpy>=1.7
    scikit-learn 0.23.2 depends on numpy>=1.13.3
    scipy 1.4.1 depends on numpy>=1.13.3
    seaborn 0.11.1 depends on numpy>=1.15
    shap 0.37.0 depends on numpy
    statsmodels 0.12.2 depends on numpy>=1.15
    torch 1.8.1 depends on numpy
    xgboost 1.4.1 depends on numpy
    causalml 0.10.0 depends on numpy<1.19.0 and >=0.16.0

Types of changes

What types of changes does your code introduce to CausalML? Put an x in the boxes that apply

  • [x ] Bugfix (non-breaking change which fixes an issue)
  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [ ] Documentation Update (if none of the other choices apply)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • [ x] I have read the CONTRIBUTING doc
  • [ x] I have signed the CLA
  • [ x] Lint and unit tests pass locally with my changes
  • [ x] I have added tests that prove my fix is effective or that my feature works
  • [ x] I have added necessary documentation (if appropriate)
  • [ x] Any dependent changes have been merged and published in downstream modules

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc. This PR template is adopted from appium.

DanielDaCosta avatar Jul 05 '21 19:07 DanielDaCosta

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Jul 05 '21 19:07 CLAassistant

Thanks @DanielDaCosta for your contribution here!

Hi @jeongyoonlee I have a quick question, do you think if it's possible for us to set up the unit test for the environment YAML file here to check if the changes can pass or not? Or the reviewers can test it on their local, any suggestions here? Thanks!

ppstacy avatar Jul 06 '21 17:07 ppstacy

Thanks, @DanielDaCosta, for the contribution. This is just because latest causalml with updated dependencies hasn't been published to PyPI yet. It'd be better not to lower the numpy version in the environment file, but install dependencies without causalml by commenting it out, then install latest causalml from GitHub or local directory directly.

@ppstacy, it might be possible to set up GitHub Action to test conda environment files. Let's look into it.

jeongyoonlee avatar Jul 06 '21 17:07 jeongyoonlee