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

关于代码运行的问题(A question about how to execute this code) #3

Closed
mikutown opened this issue Sep 3, 2022 · 18 comments
Closed

Comments

@mikutown
Copy link

mikutown commented Sep 3, 2022

你好,我下载了你的代码,发现无法运行,报错为:FileNotFoundError: [Errno 2] No such file or directory: './FJSSPinstances/Vdata',然后我新建了路径/FJSSPinstances/Vdata发现不报错了,但是输出为空,可能是Vdata中没有放文件的缘故,请问Vdata中应该放什么文件进去?我放了0_BehnkeGeiger中的文件,然后代码在permissibleLS.py"中报错, line 320, in
path_list.sort(key=lambda x:int(x[2:-4])) ValueError: invalid literal for int() with base 10: 'hnke50',放入另一个文件夹的文件也是一样报错,请问Vdata中应该放入什么文件才能让代码正常运行?

@mikutown
Copy link
Author

mikutown commented Sep 3, 2022

English version:
Hello, I downloaded your code and found it could not run. The error is: filenotfounderror: [errno 2] no such file or directory: '/ Fjsspinstances / Vdata ', and then I created a new path / fjsspinstances / Vdata. I found that there was no error, but the output was empty. It may be because there was no file in Vdata. What file should be put in Vdata? I put 0_ Behnkegeiger, and then the code in permissiblels Py "medium error, line 320, in"
path_ list. Sort (key = lambda x: int (x [2: - 4]) valueerror: invalid literal for int() with base 10: 'hnke50', the same error is reported for files placed in another folder. What files should be placed in Vdata to make the code run normally?

@Lei-Kun
Copy link
Owner

Lei-Kun commented Sep 3, 2022

@mikutown
Copy link
Author

mikutown commented Sep 3, 2022 via email

@mikutown
Copy link
Author

mikutown commented Sep 4, 2022

已经运行成功,感谢博主的耐心指导!要运行代码需要在代码中新建一个文件夹FJSSPinstances,然后将测试数据文件夹都放进去,然后把代码中对应的路径名改为需要运行的文件夹,然后在permissible.py文件的get_imlist函数中修改path_list.sort(key=lambda x:int(x[6:-4]))中的数字6,按照文件夹中数据集文件的英文字母个数进行修改 然后就可以跑通了!最后给博主一个建议,希望可以提供一下environment.txt 这样就不用一个一个的装包了hhhhhh

@mikutown mikutown closed this as completed Sep 4, 2022
@Lei-Kun
Copy link
Owner

Lei-Kun commented Sep 4, 2022

没事没事,如果对您有帮助后续可以引用咱们的论文

@Lei-Kun Lei-Kun pinned this issue Sep 4, 2022
@Akhilnandh
Copy link

Hello, How to run your file? I am looking to cite your work- I am not sure how to go about running your file though its relevant to mine

@Akhilnandh
Copy link

Which file to run to get the makespan

@Lei-Kun
Copy link
Owner

Lei-Kun commented Nov 11, 2022

Hello, How to run your file? I am looking to cite your work- I am not sure how to go about running your file though its relevant to mine

Hello, thanks for your interest in our work. You can download from FJSP benchmark website https://github.com/leikun-starting/FJSP-benchmarks to test other FJSP instances. Then you can create a file named FJSSPinstances and put the benchmarks in this file. Last, you can run the permissible.py to get the makespan.

@Lei-Kun
Copy link
Owner

Lei-Kun commented Nov 11, 2022

I'd like to stress that you should revise the path of the benchmark instance that you want to test in the permissible.py.

@Akhilnandh
Copy link

Akhilnandh commented Nov 11, 2022

Thanks alot for the prompt response.
Also, would you be able to let me know where to modify the fitness function (makespan in this case), but what if we want another objective function?

@Akhilnandh
Copy link

Looking forward to hearing your thoughts
Thank you,
your original code works when I made the modifications. !

@Lei-Kun
Copy link
Owner

Lei-Kun commented Nov 11, 2022

Thanks alot for the prompt response. Also, would you be able to let me know where to modify the fitness function (makespan in this case), but what if we want another objective function?

I'm sorry I cannot understand the fitness function you mentioned. This code involved eight dispatching rules specifies minimizing the objective function of max makespan.

@Akhilnandh
Copy link

Akhilnandh commented Nov 11, 2022 via email

@Lei-Kun
Copy link
Owner

Lei-Kun commented Nov 11, 2022

I think you need to adjust the computation of the objective in this code if you want to leverage it to optimize other objective functions. And that will need a large-scale adjustment of this code.

@Akhilnandh
Copy link

Yes that is alright,
a bit more explanation on which function of which program/sub program computes the start time and end time would be great.
Looking forward to hearing your thoughts.

@Lei-Kun
Copy link
Owner

Lei-Kun commented Nov 11, 2022

In the FJSP_env.py, there is an start and end time list for recording the makespan of each job. The main definitions is located in the FJSP_env.py, you can revise it for the objective what you want, I guess.

@William1234nn
Copy link

untimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.FloatTensor [32, 1]], which is output 0 of AsStridedBackward0, is at version 4; expected version 3 instead. Hint: enable anomaly detection to find the operation that failed to compute its gradient, with torch.autograd.set_detect_anomaly(True).
image

您好,我在运行训练函数时出现错误这个错误改如何解决?

@Lei-Kun
Copy link
Owner

Lei-Kun commented Dec 14, 2022 via email

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

4 participants