Electrostatics / apbs-pdb2pqr

APBS - software for biomolecular electrostatics and solvation
http://www.poissonboltzmann.org/
127 stars 62 forks source link

Bug in psize.py? #525

Closed Jerkwin closed 5 years ago

Jerkwin commented 5 years ago

In apbs-pdb2pqr/apbs/tools/manip/psize.py, line 166

        zofac = 1 + 2 * self.constants["ofrac"]
        for i in range(3):
            self.np[i] = n[i]/float(nsmall[i])
166         if self.np[i] > 1: self.np[i] = int(zofac*n[1]/nsmall[i] + 1.0)
        return self.np

Should n[1]/nsmall[i] be n[i]/nsmall[i] ? Otherwise, I can't understand the logic.

sobolevnrm commented 5 years ago

Hello--

This does look like a bug. I'll check with others on the development team for a fix.

Thank you,

Nathan


From: Jerkwin notifications@github.com Sent: Tuesday, July 30, 2019 7:33 AM To: Electrostatics/apbs-pdb2pqr apbs-pdb2pqr@noreply.github.com Cc: Subscribed subscribed@noreply.github.com Subject: [Electrostatics/apbs-pdb2pqr] Bug in psize.py? (#525)

In apbs-pdb2pqr/apbs/tools/manip/psize.py, line 166

            zofac = 1 + 2 * self.constants["ofrac"]
            for i in range(3):
                    self.np[i] = n[i]/float(nsmall[i])

166 if self.np[i] > 1: self.np[i] = int(zofac*n[1]/nsmall[i] + 1.0) return self.np

Should n[1]/nsmall[i] be n[i]/nsmall[i] ? Otherwise, I can't understand the logic.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://nam05.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FElectrostatics%2Fapbs-pdb2pqr%2Fissues%2F525%3Femail_source%3Dnotifications%26email_token%3DAAOX7WADBQJKVRBZI4BNIOTQCBGKFA5CNFSM4IH5ATCKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HCKFA2A&data=02%7C01%7C%7C50b1a61889914def9bef08d714fad7ab%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637000939892934884&sdata=XDJ2Ok4Y4peM8GIl9hSuU1ExFzgmvx5XPcdUW8hbSpI%3D&reserved=0, or mute the threadhttps://nam05.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAAOX7WDGNKDAUCUX7XYROMDQCBGKFANCNFSM4IH5ATCA&data=02%7C01%7C%7C50b1a61889914def9bef08d714fad7ab%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637000939892954888&sdata=wX4JupbXufV9Ew2y4QB1iKe%2BAhJvB4zYhn%2BnHbr94Q8%3D&reserved=0.

Jerkwin commented 5 years ago

Hi Nathan,

Any responses from the development team? I would like to make sure this is indeed a bug.

Thanks, Jicun

sobolevnrm commented 5 years ago

Hello –

I apologize that I have not. I will Cc them again.

Thank you,

Nathan

From: Jerkwin notifications@github.com Sent: Friday, 9 August, 2019 07:06 To: Electrostatics/apbs-pdb2pqr apbs-pdb2pqr@noreply.github.com Cc: Nathan Baker nathanandrewbaker@gmail.com; Comment comment@noreply.github.com Subject: Re: [Electrostatics/apbs-pdb2pqr] Bug in psize.py? (#525)

Hi Nathan,

Any responses from the development team? I would like to make sure this is indeed a bug.

Thanks, Jicun

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FElectrostatics%2Fapbs-pdb2pqr%2Fissues%2F525%3Femail_source%3Dnotifications%26email_token%3DAAOX7WFPTDMKXZVXKQQJN3TQDV2VPA5CNFSM4IH5ATCKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD36YURQ%23issuecomment-519932486&data=02%7C01%7C%7C549d03f4d5ff427ca7bf08d71cd2bf66%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637009563782336682&sdata=mK840KfsJFwSiEU4locCGFmjmIIV3NL5ckD8pR5dbvA%3D&reserved=0, or mute the threadhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAAOX7WGGD2VFMYBRSX7T6Z3QDV2VPANCNFSM4IH5ATCA&data=02%7C01%7C%7C549d03f4d5ff427ca7bf08d71cd2bf66%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637009563782346692&sdata=01M6zAz%2FVD3Fa6fTbjcQr2SzRn50EH%2BK2Ce3nKjRxjA%3D&reserved=0.

Eo300 commented 5 years ago

Hi Jicun,

I went and patched a fix for this in the most recent commit f83c140. Both psize.py files in the apbs/tools/manip and pdb2pqr/src directories should now be reflected to use the index i instead of 1.

Thanks for informing us of this!

-Elvis

sobolevnrm commented 5 years ago

Jicun, we have made the change. Thanks for finding the error.

Sent from my iPhone

On Aug 9, 2019, at 3:56 PM, Nathan Baker nathanandrewbaker@gmail.com<mailto:nathanandrewbaker@gmail.com> wrote:

Hello –

I apologize that I have not. I will Cc them again.

Thank you,

Nathan

From: Jerkwin notifications@github.com<mailto:notifications@github.com> Sent: Friday, 9 August, 2019 07:06 To: Electrostatics/apbs-pdb2pqr apbs-pdb2pqr@noreply.github.com<mailto:apbs-pdb2pqr@noreply.github.com> Cc: Nathan Baker nathanandrewbaker@gmail.com<mailto:nathanandrewbaker@gmail.com>; Comment comment@noreply.github.com<mailto:comment@noreply.github.com> Subject: Re: [Electrostatics/apbs-pdb2pqr] Bug in psize.py? (#525)

Hi Nathan,

Any responses from the development team? I would like to make sure this is indeed a bug.

Thanks, Jicun

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FElectrostatics%2Fapbs-pdb2pqr%2Fissues%2F525%3Femail_source%3Dnotifications%26email_token%3DAAOX7WFPTDMKXZVXKQQJN3TQDV2VPA5CNFSM4IH5ATCKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD36YURQ%23issuecomment-519932486&data=02%7C01%7C%7C549d03f4d5ff427ca7bf08d71cd2bf66%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637009563782336682&sdata=mK840KfsJFwSiEU4locCGFmjmIIV3NL5ckD8pR5dbvA%3D&reserved=0, or mute the threadhttps://nam04.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAAOX7WGGD2VFMYBRSX7T6Z3QDV2VPANCNFSM4IH5ATCA&data=02%7C01%7C%7C549d03f4d5ff427ca7bf08d71cd2bf66%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637009563782346692&sdata=01M6zAz%2FVD3Fa6fTbjcQr2SzRn50EH%2BK2Ce3nKjRxjA%3D&reserved=0.

Jerkwin commented 5 years ago

Thanks for the fix.