Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows 11 FileNotFoundError when attempting to run the CSP task #26

Open
hasan-sayeed opened this issue Oct 2, 2024 · 1 comment
Open

Comments

@hasan-sayeed
Copy link

First of all, I want to say this is a great project! I read your paper on DiffCSP, and I was really excited to try it out. The approach and insights you presented are fascinating, and I’m eager to apply this to my work. However, I’ve run into an issue that I hope someone can help me with.

Description:

I’m attempting to run the CSP task using the DiffCSP repository on my Windows 11 laptop with an RTX 4060 GPU. I followed the environment setup instructions provided in txie-93/cdvae#63 (comment), and https://github.com/jiaor17/DiffCSP?tab=readme-ov-file#dependencies-and-setup but I’m encountering a FileNotFoundError when running the command: python diffcsp/run.py data=mp_20 expname=mp_20

Error:

File "C:\Users\hsayeed\miniconda3\envs\cdvae_copy_3\lib\site-packages\multiprocess\spawn.py", line 116, in spawn_main
    _fixup_main_from_path(data['init_main_from_path'])
  File "C:\Users\hsayeed\miniconda3\envs\cdvae_copy_3\lib\site-packages\multiprocess\spawn.py", line 287, in _fixup_main_from_path
    exitcode = _main(fd, parent_sentinel)
  File "C:\Users\hsayeed\miniconda3\envs\cdvae_copy_3\lib\site-packages\multiprocess\spawn.py", line 125, in _main
    main_content = runpy.run_path(main_path,
  File "C:\Users\hsayeed\miniconda3\envs\cdvae_copy_3\lib\runpy.py", line 264, in run_path  
    prepare(preparation_data)
  File "C:\Users\hsayeed\miniconda3\envs\cdvae_copy_3\lib\site-packages\multiprocess\spawn.py", line 236, in prepare
    code, fname = _get_code_from_file(run_name, path_name)
  File "C:\Users\hsayeed\miniconda3\envs\cdvae_copy_3\lib\runpy.py", line 234, in _get_code_from_file
    _fixup_main_from_path(data['init_main_from_path'])
  File "C:\Users\hsayeed\miniconda3\envs\cdvae_copy_3\lib\site-packages\multiprocess\spawn.py", line 287, in _fixup_main_from_path
    with io.open_code(decoded_path) as f:
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\hsayeed\\Documents\\GitHub\\HYDRA_JOBS\\singlerun\\2024-10-02\\mp_20\\diffcsp\\run.py'

System Setup:

OS: Windows 11
GPU: RTX 4060
Python environment: Miniconda, cdvae_copy_3 environment
.env file:

export PROJECT_ROOT="C:\Users\hsayeed\Documents\GitHub\DiffCSP"
export HYDRA_JOBS="C:\Users\hsayeed\Documents\GitHub\HYDRA_JOBS"
export WABDB_DIR="C:\Users\hsayeed\Documents\GitHub\WABDB_DIR"

Additional Context:
I found an open issue here: #11 (comment) in the repository, which suggests that DiffCSP is more suited for Linux environments, and there might be incompatibility with Windows. I don't have access to a Linux machine at the moment, so I’m wondering if there’s a way to make this work on Windows.

Questions:

  • Is this code designed specifically for Linux environments?
  • Are there any known workarounds for running DiffCSP on Windows 11?
  • Or am I missing any steps to ensure compatibility on Windows?

I’d really appreciate it if anyone could help me resolve this issue. Thanks in advance for your time and for this fantastic project!

@hasan-sayeed
Copy link
Author

I was able to solve this issue, and I'm sharing the solution here for anyone who may face the same problem in the future.

  • I am working on a Windows machine and do not have access to a Linux environment, so I installed WSL (Windows Subsystem for Linux) to resolve this.

  • I then updated the env.yml file of the CDVAE code by pasting the environment configuration from this comment, and created the environment following the rest of the instructions from that link.

  • Additionally, I installed the required packages listed here.

After these steps, I was able to successfully run the CSP task.

I hope this helps anyone facing similar issues. Feel free to reach out if you have any further questions or need clarification. Thanks again to the developers for this great project!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant