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

单独运行排序算法模块出错 #5

Open
AlterWL opened this issue Jan 21, 2020 · 1 comment
Open

单独运行排序算法模块出错 #5

AlterWL opened this issue Jan 21, 2020 · 1 comment

Comments

@AlterWL
Copy link

AlterWL commented Jan 21, 2020

应该是要去掉 data 前的点,不然找不到 data 模块

图片

@AlterWL
Copy link
Author

AlterWL commented Jan 21, 2020

又试了一下,发现如果直接删去点,会导致 main.py 运行出错。所以我觉得这样可以兼顾。

from .data import DataSeq

改为

if __name__ == "__main__":
    from data import DataSeq
else:
    from .data import DataSeq

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