deligentfool / mfrl_pytorch

Implementation of Mean Field Multi-Agent Reinforcement Learning in Pytorch
14 stars 1 forks source link

`pip install -r requirements.txt` got error #1

Closed liqwang closed 6 months ago

liqwang commented 6 months ago

My environment is linux-x64 with Python 3.9.18

After I execute pip install -r requirements.txt, I got the following error caused by dependency conflict:

The conflict is caused by:
    The user requested numpy==1.21.2
    array2gif 1.0.4 depends on numpy
    contourpy 1.0.6 depends on numpy>=1.16
    gym 0.21.0 depends on numpy>=1.18.0
    imageio 2.13.3 depends on numpy
    magent 0.1.14 depends on numpy>=1.18.0
    matplotlib 3.6.2 depends on numpy>=1.19
    mkl-fft 1.3.1 depends on numpy<1.23.0 and >=1.22.3

To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict

ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/topics/dependency-resolution/#dealing-with-dependency-conflicts

Besides the dependency conflict problems, there are other problems in requirements.txt:

liqwang commented 6 months ago

I try to fix the above dependency conflict error by changing numpy version to 1.22.3

- numpy==1.21.2
+ numpy==1.22.3

Then I got another dependency conflict error:

The conflict is caused by:
    The user requested numpy==1.22.3
    array2gif 1.0.4 depends on numpy
    contourpy 1.0.6 depends on numpy>=1.16
    gym 0.21.0 depends on numpy>=1.18.0
    imageio 2.13.3 depends on numpy
    magent 0.1.14 depends on numpy>=1.18.0
    matplotlib 3.6.2 depends on numpy>=1.19
    mkl-fft 1.3.1 depends on numpy<1.23.0 and >=1.22.3
    mkl-random 1.2.2 depends on numpy<1.25.0 and >=1.24.3

To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict

ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/topics/dependency-resolution/#dealing-with-dependency-conflicts
deligentfool commented 6 months ago

Thank you very much for raising the issue regarding requirements.txt. I have already updated the requirements.txt file. Please do not hesitate to contact me if you have any further questions.

liqwang commented 6 months ago

Thank you very much!