FeTS-AI / Challenge

The repo for the FeTS Challenge
https://www.synapse.org/#!Synapse:syn28546456
49 stars 29 forks source link

Installation error on step 'pip install .' #188

Open RishiPandey06 opened 1 year ago

RishiPandey06 commented 1 year ago

Hi, I am getting this error while on the step on pip install . given in the readme. I have been trying to solve this for the past 1 week I do not understand the cause for this error. error image

Here's my pytorch config: image

Please let me know what I might be doing wrong or the changes I need to make, I'm running the exact same code mentioned in the readme even for the venv setup.

Thank you

mzenk commented 1 year ago

Hi Rishi, I assume you're talking about the task 1 readme. @RishiPandey06 can you send the complete output of the pip install command instead of a screenshot? Maybe someone from the task-1 team help? (e.g. @brandon-edwards @psfoley; maybe also @Geeks-Sid because the screenshot looks similar to an error reported in issue #172)? Since the challenge is currently not active, however, I'm not sure if someone from the Task-1 team is available soon, unfortunately...

RishiPandey06 commented 1 year ago

That was the whole error actually, and I saw the issue you mentioned but it only gave a solution for "gandalf" and not the issue I have. Here is the entire error log I'm getting on pip install .

Looking in indexes: https://pypi.org/simple, https://pypi.ngc.nvidia.com Processing d:\work\uofg\fets\challenge\task_1 Preparing metadata (setup.py) ... done Collecting openfl@ git+https://github.com/intel/openfl.git@f4b28d710e2be31cdfa7487fdb4e8cb3a1387a5f (from fets-challenge==2.0) Cloning https://github.com/intel/openfl.git (to revision f4b28d710e2be31cdfa7487fdb4e8cb3a1387a5f) to c:\users\hrish\appdata\local\temp\pip-install-niwmgaze\openfl_e197059e5cad4bb0897eb6f8b5339948 Running command git clone --filter=blob:none --quiet https://github.com/intel/openfl.git 'C:\Users\hrish\AppData\Local\Temp\pip-install-niwmgaze\openfl_e197059e5cad4bb0897eb6f8b5339948' Running command git rev-parse -q --verify 'sha^f4b28d710e2be31cdfa7487fdb4e8cb3a1387a5f' Running command git fetch -q https://github.com/intel/openfl.git f4b28d710e2be31cdfa7487fdb4e8cb3a1387a5f Running command git checkout -q f4b28d710e2be31cdfa7487fdb4e8cb3a1387a5f Resolved https://github.com/intel/openfl.git to commit f4b28d710e2be31cdfa7487fdb4e8cb3a1387a5f Preparing metadata (setup.py) ... error error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [8 lines of output] Traceback (most recent call last): File "", line 2, in File "", line 34, in File "C:\Users\hrish\AppData\Local\Temp\pip-install-niwmgaze\openfl_e197059e5cad4bb0897eb6f8b5339948\setup.py", line 79, in long_description = f.read() File "c:\python38\lib\encodings\cp1252.py", line 23, in decode return codecs.charmap_decode(input,self.errors,decoding_table)[0] UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d in position 6189: character maps to [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed

× Encountered error while generating package metadata. ╰─> See above for output.

note: This is an issue with the package mentioned above, not pip. hint: See above for details.

sunyeongan commented 8 months ago

@RishiPandey06
Did you solve this problem? I'm experiencing the same problem.

--------ERROR LOG-----

error: subprocess-exited-with-error

× python setup.py egg_info did not run successfully. │ exit code: 1 ╰─> [6 lines of output] Traceback (most recent call last): File "", line 36, in File "", line 34, in File "C:\Users\asy10\AppData\Local\Temp\pip-install-0z8h_xpk\openfl_d27e7e9e78a04859acbb29d3ae303817\setup.py", line 79, in long_description = f.read() UnicodeDecodeError: 'cp949' codec can't decode byte 0xe2 in position 5002: illegal multibyte sequence [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed

× Encountered error while generating package metadata. ╰─> See above for output.

note: This is an issue with the package mentioned above, not pip. hint: See above for details.

PandeyRishiV commented 8 months ago

@sunyeongan No, sadly I had to leave this project and create a federated learning model / env of my own. You could use tensorflows federated learning library to implement the same

psfoley commented 5 months ago

@RishiPandey06 @sunyeongan - this seems to be a compatibility bug with Windows for OpenFL (OpenFL experimentally supports Windows, but issues like this do come up occassionally). If possible to move forward, I would recommend migrating to Linux while my team looks into a fix.

sunyeongan commented 5 months ago

hi @psfoley Following your advice, I am running the code in WSL on Windows in Ubuntu Linux 22.04 environment. however pip install . An error occurs in the command.

image

Perhaps this issue is https://github.com/FeTS-AI/Challenge/issues/172#issuecomment-2143756215 is connected to https://github.com/FeTS-AI/Challenge/blob/524d6b9f489ba852d601a437839abd937e5cab89/Task_1/setup.py#L32 was changed to GANDLF @ git+https://github.com/sunyeongan/GaNDLF.git@ff6417f19c4da0eb64c50afb5d436887203f63c8',

With this change it will run. But I wonder if this is right

kta-intel commented 5 months ago

Hey @RishiPandey06 @sunyeongan

Re: Windows installation issue - can you try pinning OpenFL==v1.5 in the setup.py? i.e. change https://github.com/FeTS-AI/Challenge/blob/524d6b9f489ba852d601a437839abd937e5cab89/Task_1/setup.py#L31 to openfl @ git+https://github.com/intel/openfl.git@v1.5

kta-intel commented 5 months ago

I am running the code in WSL on Windows in Ubuntu Linux 22.04 environment. however pip install . An error occurs in the command. image

Perhaps this issue is #172 (comment) is connected to

https://github.com/FeTS-AI/Challenge/blob/524d6b9f489ba852d601a437839abd937e5cab89/Task_1/setup.py#L32

was changed to GANDLF @ git+https://github.com/sunyeongan/GaNDLF.git@ff6417f19c4da0eb64c50afb5d436887203f63c8', With this change it will run. But I wonder if this is right

Hmm, I did not run into this issue on my end. I wonder if it's a network issue. Though maybe not if you aren't running into issues cloning and installing other repos from source.

Can you try updating the URL? https://github.com/FeTS-AI/Challenge/blob/524d6b9f489ba852d601a437839abd937e5cab89/Task_1/setup.py#L32 to GANDLF @ git+https://github.com/mlcommons/GaNDLF.git@e4d0d4bfdf4076130817001a98dfb90189956278

Also might be helpful to update the commit to: https://github.com/mlcommons/GaNDLF/commit/f13fb9cb9c9ceb6490611ffab3469bcdb3d6f956 (same commit but contained within that repo)

sunyeongan commented 5 months ago

thank you for the reply. @kta-intel It wasn't a network problem.

https://github.com/FeTS-AI/Challenge/blob/524d6b9f489ba852d601a437839abd937e5cab89/Task_1/setup.py#L30C5-L34C7

I solved the problem by installing each library as follows.

kta-intel commented 4 months ago

thank you for the reply. @kta-intel It wasn't a network problem.

https://github.com/FeTS-AI/Challenge/blob/524d6b9f489ba852d601a437839abd937e5cab89/Task_1/setup.py#L30C5-L34C7

I solved the problem by installing each library as follows.

Hey @sunyeongan, Thanks for the instructions. I just wanted to confirm something: did manually checking out and installing from that commit resolve the UnicodeDecodeError issue on Windows for you or was this in WSL/Linux?

sunyeongan commented 4 months ago

@kta-intel When running on WSL/Linux, no UnicodeDecodeError occurred. This error occurred only when running setup.py in a Windows environment.