Tagged Questions
0
votes
0answers
11 views
scikit-learn install and use
I have installed WinPython-64bit-2.7.5.1
I am trying to play around with scikit - learn but when I use the code:
From sklearn.ensemble import RandomForestClassifier
I get SyntaxError: Invalid ...
0
votes
1answer
19 views
Create a python tkinter window with no X (close) button
I'm writing a 'wizard' type Python Tkinter GUI that collects information from the user and then performs several actions based on the user's entries: file copying, DB updates, etc. The processing ...
0
votes
1answer
22 views
How can I make an .exe python program in windows works like a daemon?
I have a python windows console application in a .exe packaged by cx_freeze. It works fine when called by Windows Command Line. What I want to do now is simple: Get this .exe and turn it a daemon ...
-1
votes
0answers
12 views
can't play video using cv2 python in windows
I am new to opencv and I am using it with python. I am trying to play a video and detect all the faces in it, but I am stuck here: I can't play the video itself.
I tried with CaptureFromFile method ...
-3
votes
0answers
20 views
How to copy a folder from system A (windows) to system B (can be linux or windows) from system C (windows) using python or Powershell
How to transfer a folder from System A (Windows) to System B (Linux or Windows) from System C (Windows) using a Python script or Power shell command.
I am trying using Python but found no utilities ...
0
votes
0answers
24 views
Why does dllMain overrides the control-word of my FPU?
I've seen here and here that dllMain changes the control-word of my FPU, and I need to:
_control87(_CW_DEFAULT, _CW_DEFAULT);
so it will return to normal. But no one states why it is done.
Does ...
-1
votes
1answer
36 views
Error running .py from Windows 7 command prompt
I am new to python and I have just installed python 2.7.3 on Windows. I will also install django so I need to execute a file named ez_setup.py. I know it seems like an easy question and answer can be ...
2
votes
3answers
43 views
File modification times not equal after calling shutil.copystat(file1, file2) under Windows
I run the following code with Python 2.7.5. under Windows:
import os, shutil, stat, time
with open('test.txt', 'w') as f: pass # create an arbitrary file
shutil.copy('test.txt', 'test2.txt') # copy ...
0
votes
1answer
20 views
Strange Windows/Python/Popen Issue
When I run the following:
import subprocess
subprocess.check_call(('dir', shell=True))
The result always shows me the contents of C:\, no matter what directory I started the Python interpreter in. ...
1
vote
1answer
30 views
Google App Engine Launcher not starting
I'm install google app engine on my laptop and when i clicked on google app engine launcher icon, mouse change to loading icon then nothing run, nothing display and no error reported, just nothing.
...
0
votes
2answers
40 views
Python or VB script to run a batch file in background even the user logged out in windows [closed]
We need python or VB script code to run a batch file in background even the user logged out the system. The script should run always irrespective of users logged in/logged off and machine reboot.
I ...
-1
votes
0answers
18 views
Installing Watchdog for Python 3.2 in Windows
I'm attempting to install watchdog for python 3.2 in windows. Currently I do not have virtualenv or pip since I have never used them outside of ubuntu. I essentially do not understand at all how to ...
0
votes
0answers
30 views
Installed python 32 bits after 64 bits [migrated]
I wanted to use the 32 bits python because I need a module that only works with the 32 bits version, but I don't want to use the 32 bits version always, but when I run a script, it runs with the 32 ...
0
votes
0answers
31 views
gettext with python in windows, what I'm doing wrong?
I'm going slightly mad trying to set language support in a python app in Windows. I got a small cgi script that works well under a little local CGIHTTPServer.
So, I import gettext. Knowing that ...
0
votes
2answers
31 views
Write Python classes that have different behavior for Mac and Windows
I want to be able to instantiate an object whose methods will behave differently depending on the platform.
import sys
class MyClass(object):
@property
def os_is_darwin(self):
...
3
votes
0answers
30 views
Windows insists associating .py files with the wrong version of Python [migrated]
I have both Python 2.7 and Python 3.3 installed on my machine (I'm on Windows 8).
I would like .py files to be opened with Python 3.3 by default. The only Python path in the PATH environment variable ...
1
vote
0answers
14 views
How to create RAS phonebook entries using python on Windows 7?
I am using win32ras and Python 3.1 on Windows 7.
The error is:
Traceback (most recent call last):
File "<pyshell#6>", line 1, in <module>
win32ras.EditPhonebookEntry(0, None, ...
1
vote
1answer
13 views
How do I use a static checker with Eclipse?
I've recently come across flake8, which is a handy wrapper around a couple of different python static checkers, and it seems cool. But how do I use a tool like this with Eclipse? I'm interested in ...
1
vote
0answers
32 views
running a python script as Administrator in Windows
I have this small Python function:
def change_boot(self):
subprocess.call(['runas', '/user:Administrator','bcdedit'], shell=True)
However it keeps asking for the admin password ... how ...
0
votes
0answers
10 views
DropHandler for Python files stopped working
I have enabled the DropHandler for Python.File in my registry per the solution from this stackoverflow question. This worked fine for about a year, and now it has suddenly stopped working. All other ...
0
votes
1answer
47 views
os.path.join generates 4 backslashes per folder
I'm trying to write a function that finds the first instance of a particular file in the current directory and its subfolders, and returns the relative path as a string.
def ...
1
vote
2answers
31 views
Python - Change Desktop Background Fast
I was wondering if there was any way to - in Python - change the desktop background of a Windows 7 machine quickly. Right now I'm using:
ctypes.windll.user32.SystemParametersInfoA(20, 0, ...
1
vote
1answer
26 views
python bottle can run two programs on the same address and port on WINDOWS
I just encountered a weird issue about bottle on windows.
When I tested the my bottle codes, I found that it could run multiple same programs on WINDOWS using same address and port. But when you try ...
1
vote
1answer
46 views
How can I install C compiler properly for Python package installation for Windows?
I believe I don't have my C compiler properly installed. I'm trying to install some Python 2.7 packages on my Windows 8 machine. I keep receiving the following error:
"RuntimeError: Broken ...
0
votes
2answers
37 views
alternative of grep in python running on Windows [duplicate]
I'm extracting the first line that starts with 'abc' in a file
grep -w 'abc' --max-count=1 file.tsv
I wanna use it in a python program
import subprocess
process = subprocess.Popen("grep -w 'abc' ...
1
vote
0answers
10 views
Celery task timeout/time limit for windows?
I have a web app written in Flask that is currently running on IIS on Windows (don't ask...).
I'm using Celery to handle some asynchronous processing (accessing a slow database and generating a ...
-1
votes
2answers
56 views
Decomposing a Series in Python
I have a series in python that looks as follows:
I want the split the series into users with Windows operating systems and those who are not using Windows operating systems. Is there a way to do ...
6
votes
1answer
76 views
Iterate over a very large number of files in a folder
What is the fastest way to iterate over all files in a directory using NTFS and Windows 7, when the filecount in the directory is bigger than 2.500.000?
All Files are flat under the top-level ...
0
votes
0answers
28 views
How to configure Python Kivy for PyCharm on Windows?
I'm having trouble getting Kivy to work with PyCharm on Windows 7. I've managed to add most of the external libraries through File > Settings > Python interpreters > Paths Tab.
I'm using the Kivy ...
0
votes
0answers
27 views
Using Python to build Windows Phone 8 applications?
I've some stuff written in Python. I would like to implement the code as an app on WP8 platform. Any idea on how I can go about compiling Python for WP8?
I tried Googling, but that turned my brain ...
0
votes
1answer
24 views
Aptana Python 2.7 issues
I pulled a script from the net to see if everything was working fine before I start programming. I'm a noob and cannot figure out what is going on. I installed easy_install to smooth things, ...
0
votes
2answers
36 views
Python parsing many word documents
I wrote a small program which extract data from a word document and process it. The tool runs only on Windows (XP) and uses the PyWin32 Library.
Everything works but sometimes I have the following ...
0
votes
0answers
21 views
What's wrong with my newly installed PyGame? Details in description
My Python version is 2.7 and whenever I try doing import pygame it shows the following error message:
Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
import ...
0
votes
1answer
53 views
Windows 8 + Emacs 24.3 + emacs-for-python: Pymacs helper did not start within 30 seconds
I recently installed Emacs 24.3 and try to use it coding for Python (v3.3.2 x86-64 MSI installer). (I'm new to Emacs). Then i try to install emacs-for-python by unpack the zip to
...
0
votes
1answer
25 views
closurebuilder.py error on Windows: “can't decode byte 0x8f”
I'm attempting to run closurebuilder.py on Windows, and no matter what files I pass, I get the same error from Python:
python goog\closure\bin\build\closurebuilder.py --root=goog/closure/goog/ ...
0
votes
0answers
43 views
Change Windows Background from Python
Does anyone know a way to change the Windows Desktop Wallpaper with python so that the change is permanent? I have found this code
import ctypes
SPI_SETDESKWALLPAPER = 20
...
0
votes
0answers
35 views
copy file to linux machine via UNC path using python
I need to copy a file from a distributed storage network to my linux machine. I only get the UNC path to the file from a database. There are about 20 servers with more than 30 shares on each server, ...
-1
votes
0answers
25 views
python-get physical disk info from logical path
I have the logical paths. For instance:-
path1='C:/abc', path2='E:/xyz'
I want to check if both of them reside on same physical disk.
Or in general I want to map a logical path to associated ...
-3
votes
0answers
51 views
how to install matplotlib in windows
how to install matplotlib on windows. I have already installed python.
and when I use networkx. It work fine. But when I use the code nx.draw(G) for drawing a graph an error appears
RuntimeError: ...
0
votes
0answers
17 views
debug-mode python on windows
For debugging an application I need to build the debug version of PyQt4 python modules on windows XP.
In the end files like PyQt4/QtCore_d.pyd are produced.
However these files can't be loaded ...
0
votes
2answers
36 views
Add python27 to windows path while using python 3.3
I use python 3.3.2 on windows everyday, so i added C:\Python33 to my PATH in order to be able to call "python foo.py" from console and get python 3.3.2 to execute it.
But sometimes, i also need to ...
1
vote
0answers
61 views
Undefined References to Python DLL Variables
I'm trying to embed Python 3.3 in my 64 bit application, but my linker is generating these errors:
=== Sandblox, Windows ===
obj\Windows\python\version.o:version.cpp undefined reference to ...
4
votes
2answers
55 views
Copy using the Windows copy dialog
I'm currently using shutil.copy2() to copy a large number of image files and folders (anywhere between 0.5 and 5 gigs). Shutil works fine, but it's so slow. I'm wondering if there is a way to pass ...
0
votes
1answer
50 views
How do I start a http server and then open a web browser?
I´m trying this:
import multiprocessing
from wsgiref.simple_server import make_server
import webbrowser
import time
def application(environ, start_response):
start_response("200 OK", ...
0
votes
2answers
120 views
Your best library for create GUI with Python (PyQt, PyGTK, wxPython, IronPython, etc) [closed]
In your opinion, what is the best way to create gui in Windows with python ?
Do you recommend PyQt for windows?
0
votes
1answer
139 views
How to install pyQt5 on Windows?
When I try installing the pyQt5 (on Windows) using the command python configure.py I get this error:
Error: Make sure you have a working Qt qmake on your PATH.
I got the pyQt5 here: ...
0
votes
0answers
31 views
Python 2.7: How to display a widget past the root window edge
I have created my own combobox in order to get a google like dropdown tied to an entry field. It is an entry box with a frame containing labels that the user can select from while still keeping focus ...
-1
votes
0answers
49 views
Lock Windows screen in python
I am in the process of creating an application for locking the computer for my little brother :)
Im using python and PyQt to create gui.
My question is how to lock screen and show only one window ...
0
votes
2answers
44 views
How to pass variables from Python to CMD in Windows
I am writing a Python (2.5) script that will search through a folder, grab a specific file, and then pass the file and a command to a CMD shell in Windows. This needs to be done with the command ...
0
votes
1answer
35 views
Trouble installing Turbulenz
I was trying out the HTML5 Game Engine Turbulenz, which requires Python to be installed on the machine. I downloaded and installed Python, and then I downloaded the installer for Turbulenz. In the ...