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

SyntaxError: invalid syntax #89

Open
jintianyun56 opened this issue Oct 6, 2023 · 1 comment
Open

SyntaxError: invalid syntax #89

jintianyun56 opened this issue Oct 6, 2023 · 1 comment

Comments

@jintianyun56
Copy link

jintianyun56 commented Oct 6, 2023

Hi there,
I have settings.cfg but have to change ConfPrune.pyx as ConfPrune.py, otherwise, the PyDP4.py can't find ConfPrune.
I tried to run the sample AT1.sdf.
Running "PyDP4.py -s chloroform -m m -B 6-311g* -F mPW1PW91 --AssumeDFTDone AT1_ AT1NMR" in the ./MM/ file show error

File "/home/tj/DP5_master/ConfPrune.py", line 37
cdef long int c1, c2
^^^^
SyntaxError: invalid syntax

would you like to help me to fix it?
Thanks

@ruslankotl
Copy link
Contributor

It looks like you have a problem with Cython. I suggest the following workaround:

  1. delete ConfPrune.pyx from your DP5 folder
  2. download ConfPrune.txt and paste into your DP5 folder as ConfPrune.py
  3. In PyDP4.py, replace the following lines:
if os.name == 'nt':
    import pyximport

    pyximport.install()
    import ConfPrune
else:
    import pyximport

    pyximport.install()
    import ConfPrune

with import ConfPrune

Let me know if this helps

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

2 participants