I need to control the frequency at which main processes data. In the example, it just increases the value of a variable. I cannot use sleep inside of main because I need the frequency to be constant (and I don't know exactly how long does it take to process all the data). I just know for a fact that whatever processing I need to do takes less than 2 seconds, so I just need to prevent main from increasing x …
我在Windows 8计算机上使用Python 2.7.9.
我尝试通过pip install lxml在键入后键入Windows PowerShell 来安装lxml python,但是我收到以下错误:SyntaxError: invalid syntax
我尝试使用以下教程http://www.tylerbutler.com/2012/05/how-to-install-python-pip-and-virtualenv-on-windows-with-powershell/安装pip,后来才意识到我第一次安装Python时已经安装了pip.exe,pip2.7.exe和pip2.exe.它们位于C:\ Python27\Scripts目录中.
然而,如果我尝试类似的东西,pip help我将得到无效的语法错误.
我是否必须重新安装pip或如何使其工作以安装lxml库.
感谢您提供任何帮助.