0
votes
1answer
15 views

Run a cmd command with a simple button in wxpython

Hi guys i have made a simple gui to to run a single line of code, until now i run via cmd the command is youtube-dl.py http://www.youtube.com/ --extract-audio --audio-format mp3 now i want to run ...
0
votes
1answer
8 views

Read csv edgelist into networkx

I have a dataset in the format of: 1,2 2,3 1,3 etc. (each pair represents an edge between the two nodes, e.g. '1,2' is an edge between node 1 and node 2) I need to read this into networkx. ...
0
votes
1answer
35 views

Generate a list of lists from an iteration

Here is an example of the problem I'm trying to solve: d=[1,2,3] e=[d[0],d[1]] def add_up(x,y): return (x + y) My attempt: h=[[add_up(a,b)] for a in e for b in d] print h output from my ...
0
votes
0answers
5 views

Xively extract current datastream value

I'm able to extract the latest value of the datastream using the following code BUT the problem is that if I change the value or update the value at the Xively dashboard console then the code isn't ...
-2
votes
3answers
80 views

Program doesn't work as expected

I can't get why the part not_com_word doesn't print the guessed characters together. Now in each loop in the guess function the not_com_word that stands for not completed word must show the guessed ...
0
votes
1answer
42 views

TypeError: int is not callable

So I did my research but I still cant figure out why Im getting this error: TypeError: int is not callable Heres my code: count = [] for row in Matrix: count.append(row[0][0].Value) results ...
-1
votes
0answers
33 views

Correct username and password but can't login to Django admin

I started learning Django for my web server. I use complete tutorial from this book. It work properly. However, I can't login to administrator although I have typing username and password correctly. ...
0
votes
0answers
24 views

Press any key to continue (Python, Crossplatform solution)

I'm trying to create one behavior of the script on Linux/Mac/Windows machines with Python 2.7.x. With a little help from this thread: http://stackoverflow.com/a/7259460/2786370 I can achieve desired ...
0
votes
0answers
23 views

given custom weight for a sparse matrix in python [on hold]

i have a matrix like that 1 2 3 4 5 ... 1 1.000000 --- --- --- --- 2 --- 1.000000 --- ...
0
votes
1answer
38 views

How to get all class attr names from derived class using boost::python?

I want to implement and use some class Base. In Python it would be like that: class Base: def Enumerate(self): d = [] for attr in dir(self): if not ...
0
votes
1answer
12 views

How to change a regular image to a Rect in pygame [duplicate]

I need the simplest way of making an image a Rect, is there a function for this or do I need to make it a Rect from the beginning? I have a script were the player moves around but I want the image of ...
0
votes
2answers
17 views

Using Python subprocess from my web application to call an external script

I want to run a Python script "test.py" in my usr/local/bin directory, which will create a text file in the same directory and write some brief text to it. This script is called by a Python ...
1
vote
1answer
38 views

Exception during groupby pandas

I am just beginning to learn analytics with python for network analysis using the Python For Data Analysis book and I'm getting confused by an exception I get while doing some groupby's... here's my ...
3
votes
3answers
45 views

Python 2.7 - find and replace from text file, using dictionary, to new text file

I am newbie to programming, and have been studying python in my spare time for the past few months. I decided I was going to try and create a little script that converts American spellings to English ...
1
vote
1answer
29 views

Cannot Install Python Modules after Installing Anaconda

I have an install of Python 2.7 on a windows machine. I just recently installed Anaconda, in addition. I just tried to install a new module for my Python install. I opened a command prompt in an ...

15 30 50 per page