Python is an interpreted, general, high-level programming language. The design emphasizes readability. It is notable for using tabs to indicate block levels. As a dynamic language, it shares many similarities to Ruby, Perl, and Scheme. The language is very popular for scientific computing and ...

learn more… | top users | synonyms

0
votes
0answers
8 views

Python 3 Unkown Coding Error

I have this Python 3 code which is causing me issues: def setStartingVariable(inputType, text, code = None, customErrorMessage = "Error: No error message"): while True: try: ...
1
vote
1answer
10 views

How to start matlab daemon

I have a plist calling a python script every day. The python script calls different matlab routines depending on their success. This works perfectly fine when I'm using the computer but when I'm not ...
-5
votes
0answers
18 views

Protein Fractal Surface [on hold]

I am trying to generate the fractal surface of the protein. The normal image of the protein can be generated using either available softwares or a short code that i have written, but i am unable to ...
0
votes
0answers
9 views

is there a way to know which class/scope a line belongs to? [on hold]

Let's say I have a file, gen_template_json.py in my example, but it doesn't really matter. I am interested in troubleshooting some code which I believe is going wrong in the classify method. Again, ...
0
votes
0answers
22 views

What kind of RAM to choose for data analysis? [on hold]

I'm planning to upgrade my computer and also want to buy some new DDR3 RAM modules. Making some research I realized that there are 2 main characteristics of RAMs (beside capacity): frequency and ...
1
vote
2answers
44 views

How to update git on RHEL without access to root?

I am trying to get my IDE set up at work for a project I am working on. I am coding in python and working in PyCharm because of its awesome git support. However, whenever I try to configure git on ...
0
votes
0answers
16 views

What is the best way to create a local development environment in a linux machine without being in sudoers

I use a workstation for my development but it does not include all the libraries for my case. I like to install them for my use without any system wide effect. How should I proceed this is a linux ...
0
votes
0answers
13 views

Is there a pure perl or python client for svn? [closed]

I was looking for something similar to phpsvnclient [https://code.google.com/p/phpsvnclient/] but didn't find any. Most options like subversion-perl or pysvn are wrappers over svn libs, and I am ...
0
votes
0answers
17 views

HTTP Error 522: Origin Connection Ti me-out [closed]

how can i fix this problem in python? "C:\Python27\lib\site-packages\mechanize_mechanize.py", line 255, in _me ch_open raise response mechanize._response.httperror_seek_wrapper: HTTP Error 522: ...
-1
votes
0answers
8 views

mechanize._response.httperror_seek_wrapper: HTTP Error 522: Origin Connection Ti me-out [duplicate]

how can i fix this problem in python File "C:\Python27\lib\site-packages\mechanize_mechanize.py", line 203, in ope n return self._mech_open(url, data, timeout=timeout) File ...
0
votes
0answers
16 views

How to install sll for python?

I have a strange problem that is described at SO http://stackoverflow.com/questions/31549052/how-to-interpret-this-traceback We got nearly nowhere trying to solve the problem though it doesn't look ...
0
votes
0answers
20 views

Mercurial fails with missing attribute using Python 2 instead of Python 3

I'm working on a multiuser system with mercurial. I haven't been using the system lately, and today I wanted to start again, but mercurial refuses to work: $ hg help *** failed to import extension ...
1
vote
2answers
17 views

Is it possible to install python packages without a direct outbound network connection?

I have a server (RHEL) that I need to install specific python packages on. However, my server is firewalled off from internet access so I am not able to install any packages using pip. Is there a ...
1
vote
0answers
12 views

In python how do I execute CMD2 5 ms after CMD1 begins executing? [closed]

CMD1 takes 1 second to finish executing. I want to execute CMD 2 exactly 5 milliseconds after CMD1 BEGINS executing.
0
votes
0answers
9 views

Add only non-python packages to path when installing anaconda

After downloading Anaconda and installing by: bash Anaconda-2.x.x-Linux-x86[_64].sh I was prompted for adding anaconda to the path. I wanted to do this to run spyder from terminal. This however, ...
0
votes
0answers
20 views

setup vim script to execute python file

I searched SO extensively and I can't get to fix this: I'm trying to code a pathogen friendly python plugin in windows. The setup would be: In \vimfiles\bundle\plugin I have a myscript.vim with: ...
0
votes
0answers
26 views

build numpy from source results in wrong architecture

I build numpy from source on my mac to link it to my ATLAS library. Thus, I wanted to run it as described here with these options: export MACOSX_DEPLOYMENT_TARGET=10.10 export CFLAGS="-arch i386 ...
0
votes
1answer
37 views

Screen-saver on and off at Raspberry Pi - script in Python

I'm a noob at programming in python. How do I make a script that awakes the monitor and put it to sleep on a condition? import RPi.GPIO as GPIO PIR = 23 GPIO.setmode(GPIO.BCM) GPIO.setup(PIR, ...
0
votes
0answers
26 views

ADB shell cmd from python script

I'm trying to retrieve and print the firmware version of my android platform using the below listed commands in a python script; import subprocess cmd = 'su -c /system/bin/mmc extcsd read ...
2
votes
1answer
36 views

How do I determine the PID of my python program if there is more then one python program running?

I have two python programs running on my system, say they are called program x and program y. I want to get the pid of program y, but not x for my bash script. When using pgrep python, I get the pid ...
0
votes
1answer
42 views

Run pip for python3 on Fedora

I can't run pip for python3 (3.4) on Fedora 22. Pip for python2.7 is installed on system by default and works fine. I install package python3-pip but can't run it. pip3, pip-3.4, python3-pip, python3 ...
0
votes
1answer
22 views

Can cron job add some information to cron log?

I am running OSX 10.10.4 and have a cron job scheduled there (it runs python script). Log file is enabled there in accordance with this answer - http://superuser.com/a/595825/172606. But the log ...
0
votes
0answers
11 views

How can I send the embedded image using python webapp

I have to be emailed the html content using python. In html content, that include also base64 encoded images. BTW, If i send the html content using python webapp, the image is not shown. So, someone ...
0
votes
0answers
7 views

Pyscripter history

Is there a way to increase the number of items shown in File>Recent Files section, which currently shows only the last 6 items, or is anyone know where this history is stored? I am using PyScripter ...
0
votes
1answer
19 views

apple store showing different page in wget

istore.apple.com live url is different that url which is downloaded using wget Open this url in browser https://itunes.apple.com/us/genre/ios-games-action/id7001?mt=8&letter=A You will see ...
0
votes
0answers
50 views

Why does python 2.7.10 install a 2.7.6 version?

I am building a custom Python 2.7.10 installation with icc via the following script: #!/bin/bash CC=icc \ CXX=icpc \ LD=xild \ CFLAGS="-O3 -xHost -fomit-frame-pointer -shared-intel -fpic -ipo ...
0
votes
0answers
12 views

Filtering of two object list by tuple attributes [migrated]

I have two list objects and I want only those elements in list1 with attribute tuples that match a tuple attribute in list2: list1= [ojec1, objec2, objec3,....] list2=[fig1,fig2,fig3,...] for i in ...
0
votes
1answer
27 views

Trouble installing pygame from a wheel file

I'm trying to install pygame(x64) from a .whl file with pip. but the cmd gives me this error: (This is the source of the wheel file: http://www.lfd.uci.edu/~gohlke/pythonlibs/) As you can see in ...
0
votes
0answers
22 views

Python/Powershell Script for Telnet

I'm most familiar with powershell and python so a solution which utilized either of them would be ideal. I'm also open to other ideas on resolving this issue. So I have a situation where an old ...
0
votes
2answers
16 views

“Edit with Idle” appears when I right click a python file, yet does not work. Also, python files show the wrong icon

My problem: http://imgur.com/a/a3D30 ...I can, however, open Idle manually, and then open the file. But this is a hassle. Another small thing. What is wrong with my python file's icon? How can I ...
0
votes
0answers
16 views

Random output from line of python code appearing in Command prompt help menu [migrated]

I was playing with the interactive Python interpreter, and decided to see what the help session said about different modules. When I typed "modules", I was given a list of modules, and a user query ...
-2
votes
0answers
18 views

How do I make a cert and key file?

I am writing a python program using ssl for the first time. I am wanting my program to send info to and back from the client in an encrypted manner. I was following the example for server-side code ...
0
votes
0answers
25 views

`pip: command not found` and other issues

I have several virtualenvs on my computer and I use them extensively. I create new ones and modify them all the time. However, when I tried to create a new one today, I found out that none of the ...
0
votes
0answers
29 views

copy column H from all files in directory into new .csv with Python

I have 50 spreadsheets in the same folder. I need to write column H from each of those files into a new .csv, and delete duplicates if possible. I've been able to get this far: import csv f = ...
1
vote
0answers
34 views

How do I use the Python commands in PowerShell?

I work in a GIS department and I'm trying to learn Python to automate something boring. I started using "Learn Python the Hard Way", but I can't figure out how to run Python scripts from PowerShell. I ...
1
vote
2answers
23 views

Python3 fails import sqlite3

I just transferred a python module from my OS X system to Ubuntu. The module runs on the Mac just fine, but fails on the Ubuntu system with the following error: import sqlite3 File ...
0
votes
1answer
23 views

Python sources on an http site, or in ISO image?

I installed SCO UnixWare 7.1.4 on VirtualBox. This installation does not include Python. I want to download the Python 2.7/2.6 source tar-ball from ftp.python.org. however: Anonymous FTP is not ...
0
votes
0answers
17 views

Script to monitor realtime CPU & Bandwidth usage in xen live migration

I need to write a script (bash or python or ??) to perform live migration of a VM in xen, and to simultaneously log and extract the CPU & bandwidth usage of the Domain-0 AND write the output into ...
0
votes
0answers
9 views

Why autopep8 does not remove double blank lines?

I specified errors like E303, E304 for fixing and yet the double blank lines, either with function/method bodies or between functions are not removed (changed to 1 newline, IIRC that's what PEP8 says) ...
1
vote
2answers
60 views

Running a Python script from the “Run” prompt

I thought this would be easy, but I've been struggling for a while. I have a Python script on my Windows machine called "myscript.py". I have it in a folder that's on my PATH, and I've added the ...
1
vote
0answers
45 views

Cannot get pip working on Python 2.6 in Fedora 22 Virtualbox

I'm working on a project that must be tested in a Fedora VM with Python 2.6.6. I have successfully installed that (so I can use that instead of the default 2.7), but I need to install some packages ...
0
votes
1answer
25 views

Installing extensions of a program that is installed twice

I have Python installed twice in my computer. The python.exe file is located once under C:\Python34 and again under C:\Anaconda3. The first was installed through the standard Python installation, ...
1
vote
0answers
31 views

Delete parts of sequential files in folders in windows

I need to find a way to delete parts of sequences of files. For example in specific folder I have several subfolders, which contain: blabla_0001.jpg blabla_0002.jpg blabla_0003.jpg blabla_0004.jpg ...
1
vote
1answer
72 views

How to efficiently and automatedly join video clips using short transitions?

I am looking to join a set of video clips (with audio) using some short transitions (ideally crossfade) in a straightforward, automated and efficient way. IE: ClipA ---> ClipB --> ClipC ...
0
votes
0answers
20 views

can't see the output of python in cmd and desktop

I've been messing around with python 3 for a while with notepad and cmd everything worked fine up until today when I saved a python file to my desktop. when I clicked on the file it said something ...
1
vote
1answer
68 views

Macro that will run in MS Excel and LibreOffice Calc

I have a spreadsheet that users will be working with in both Excel and LibreOffice Calc. I'd like to design macros that will work in both. I was thinking of code that would say: If Excel Then [VBA ...
0
votes
1answer
33 views

How to repair the permission of System Python in Mac OS X?

OS: Mac OS X 10.10.3 Cause In order to make the "YouCompleteMe" plugin works, I tampered with System Python: I renamed the folders 2.7 and Current to 2.7-sys and Current-sys respectively in ...
0
votes
1answer
27 views

Deploying Django using Phusion Passenger - file upload failure

I have a Django app deployed using Passenger (I did not choose mod_wsgi because mod_passenger is already there and being used). When I uploaded an MP3 file (900 kB), Google Chrome displays upload % ...
0
votes
0answers
120 views

Mitmproxy on windows(mitmdump) getting stuck when given a command

I have built mitmproxy with python 2.7.1 and distutils 2.7.1 for windows 32 bit,The mitmdump i got is seems well,when i open windows cmd and give following command: C:\users\myusername>mitmdump ...
0
votes
1answer
26 views

Autorun a python with sudo at startup

How can I make a python script rusn at startup on my OS X Yosemite Macbook every time? I want it to have sudo privilages as well.