I’ve never used Nuke, but I’m guessing that much like the python environment found in other DCC applications that they are using a non-standard C-runtime.
So if you want to use modules compiled for nuke with a standalone version of python you’d need to find out what compiler they built it with, and compile your own version of python to match.
Or if nuke is decent about things, they might ship their own version of the python interpreter which could be used for standalone scripts like this. Maya does this with mayapy.exe and houdini does this with hython.exe, 3DS Max does it as well, but I don’t remember what that one is called.
But on the whole, what you are currently trying to do is not possible.
That should swallow the error, but if its throwing such an error, it probably means that some module isn’t being loaded properly and you can’t guarantee that the script will work the same.