15,181 Topics
| |
Dear friends, I'm having a strange issue with a simple python code involving wx and HTML2. It is a code to run a local html page (on windows) but when I close the browser, the process stays in memory and I have to manually kill it. Here is the code, … | |
Hi there, I am bit confused about this. I am doing assignment on neuron analysis by using python neurolab. Hidden layer Architecture 1 [9-1-1] // 9=input nodes 1=hidden nodes 1=output 1 [9-2-1] // 9="" 2=hidden nodes 1=output 1 [9-3-1] 1 [9-4-1] 1 [9-5-1] 1 [9-6-1] from the description above. I … | |
I have a python script that reads a csv file and converts it to two new files so that my database can add new emails or update existing ones. What im trying to do now is after it has converted them for it to send me a email with how … | |
Hi guys, I need your help as I got stuck. I'm trying to fetch the data from my own xml which it looks like this: <?xml version="1.0" encoding="UTF-8" ?> <tv generator-info-name="www.mysite.com/xmltv"> <channel id='101 ABC FAMILY'> <display-name>101 ABC FAMILY </display-name> <programme channel="101 ABC FAMILY" start="20140520110000" stop="20140520120000"> <title lang="en">Gilmore Girls - Let … | |
can someone help me am trying to create a game that scrambles words then you have guess the corect words for it this what i have doen so far but it dint seem to work can sometell me what the problem. import tinker import random words_list = [] f = … | |
I am working on my first project. I am trying to create a program that can fetch a string from a text file when the number for that string is entered, and allow the user to edit that string if they wish. Right now I'm just trying to get menus … | |
Using the following code as a foundation (it reddens the upper left corner of an image), I was told to create 2 different programs: one that would brighten the entire image, and one that would convert the entire image to grayscale. I need major help with this. Here's the code … | |
Challenge: change the code so that only .py and .txt files of a given directory are listed. ''' filename_list_given_dir1.py use module glob to list all the filenames of .jpg files or any extension(s) you specify in a given directory ''' import glob import os # all files (split off file … | |
Hello! I have started experimenting with GUI programming using TkInter. Up to now, I have written this code: [CODE]import Tkinter, tkFileDialog, Tkconstants from Tkinter import * root = Tk() root.title('Watermark Image Processing 1.0b') #Options for buttons button_opt = {'fill': Tkconstants.BOTH, 'padx': 5, 'pady': 5} #Define asking directory button dirname = … | |
Hi I am trying to write a code that finds approximations of sine and cosine using the equations below with a given value of theta in degrees basically as a novice programmer i am having trouble setting upa a while loop for the expansions. Also can you guys please quote … | |
Hi everyone, I have 4 .py files : main.py , file1.py , file2.py , file3.py as : main.py: import sys import file1 import file2 import file3 def main(a,b): c=file1.somme(a,b) d=file2.mul(a,b) file3.div(a,b) print c,d if __name__ == '__main__': a,b=sys.argv[1:] a=int(a) b=int(b) main(a,b) file1.py: def somme(i1,i2): return i1+i2 file2.py: def mul(i1,i2): return … | |
I am looking for alternatives to setup a server in work place which does not allow to setup new software to computers to check and reserve rooms for meetings both through local network computers or possible from home / on the move. I of course would like to have thy … | |
http://pastebin.com/piCzf2sT when put a token in vertical that the main windows is full appear all the line in selected color and not only one, anyone can know why? | |
I am new to programming and I am looking for a language that is easy to learn, and a relatively useful programming language. I don't know much about programming but I want to learn and I think here is the best place to start. I want to get started on … | |
To continue[ my quiz series](http://www.daniweb.com/search/query/0?q=%22quiz+of+the%22+pytony#gsc.tab=0&gsc.q=%22quiz%20of%20the%22%20pytony&gsc.page=1), explain what happens with this code (how you would name this action and is there other way to get same result), why, and what is actually the value of `a` at end. a = ['a', 'b','e'] a[2:2] = ['c', 'd'] | |
This small script named `sourcecode.py` is a command line tool to open a python module's source file with the default editor. For example the line $ python sourcecode.py xml.dom.minidom opens the file minidom.py from the python distribution with the default editor. The same works with user-defined modules having a python … | |
so this project is basically nothing more than a python to GLSL translator. https://github.com/ncbray/pystream you have to follow the GLSL rules with the python code, so usage isn't exactly free. the problem though is Nick Bray only documented a little about how to code the shaders, and gives no examples … | |
Hi everyone, I'm new to programming (and daniweb) and I'm having a small problem with a Caeser Cipher program I'm writing. messageE = input('\nPlease enter string to encrypt: ') offsetE = int(input('Please enter offset value (1 to 94): ')) encryptedE = '' if offsetE < 1 or offsetE > 94: … | |
hi guys.. im new to this forum and im certain its here that all my problems will be solved. In fact I have a traffic simulation project in python. Im stuck at the very start since ive never programmed in python. I would like to know how to make an … | |
http://pastebin.com/embed_js.php?i=TpzkKkYW Here's what I have right now. I am basing it off this ( http://forum.codecall.net/topic/76208-tkinter-ball-snake-game/ ) and trying to change it into what I want, as I'm fairly new to python and wasn't sure how else to start. Could you guys help me make it more simple? I just want … | |
hello python developers, i recently started working on a simple xml rpc application, the simple version is completly working but when i wanted to extend it and add some more functionality i ran into some troubles. i want to register functions from different classes as server methods, i thought i … | |
This snippet shows how to find the complex roots of a polynomial using python (tested with python 2.6). You need the scipy or numpy module. | |
my code has this structure class Mapsframe(wx.Frame): def __init__(self): import application class Example(wx.Frame,listmix.ColumnSorterMixin): def __init__(self, *args, **kwargs): super(Example, self).__init__(*args, **kwargs) self.InitUI() def InitUI(self): def onItemSelected(self,event): frame = Mapsframe() and i need to pass two variables which have been created localy inside the def onItemSelected to another python script called application.py … | |
after importing pygame, when we convert an image an assign it to a variable, what is the type of that variable? | |
Hello. I am a complete newbit to Python. I am trying to read a text file (which is actually an svg file) and add a line to the text file. I would also like to remove certain text from the file. I am trying to edit some of the tags … | |
Hi there, Guys I need help in understanding the this code. Because I have been asked my lecturer to use the existing code and propose a problem through any journals which have connection with neural network and demonstrate it using the codes. Before selecting any journal, first I need to … | |
This script computes the formal series expansion of a mathematical function on the command line using the python module swiginac, an interface to the CAS Ginac. Typical invocation in a linux terminal looks like $ serexp.py -n 7 "log(1+x)*(1+x+x**2)**(-1)" 1*x+(-3/2)*x**2+5/6*x**3+5/12*x**4+(-21/20)*x**5+7/15*x**6+Order(x**7) As far as I know, swiginac does not work in … | |
i have this code import wx import datetime,re,os,time,urllib,errno import sys import wx.lib.mixins.listctrl as listmix musicdata = { 0 : ("Bad English", "The Price Of Love", "Rock"), 1 : ("DNA featuring Suzanne Vega", "Tom's Diner", "Rock"), 2 : ("George Michael", "Praying For Time", "Rock"), 3 : ("Gloria Estefan", "Here We Are", … | |
What I am trying to acheive is to parse an xml file break it up into useful components and push it to a multi table SQL database. But I cannot get off the ground in the basics. Take an xml file like this [Click Here](http://old.racingnsw.com.au/Site/_content/racebooks/20140513HAWK0.xml) Which at the start is … | |
I [saw interesting problem](http://www.daniweb.com/software-development/legacy-languages/threads/478323/prolog) of generating spiral of numbers and realized I could reuse [my code for rotation](http://www.daniweb.com/software-development/python/code/371536/rotate-sequences-left-or-right) I posted earlier. |
The End.