I'm porting some matlab functions to scilab. The cool thing is that there is a conversion toolbox that make things very easy.
The problem is I did not find the counter part to the syms function, and the symbolic toolbox in general. (I'd like a port of the Control System Toolbox too, i'm still searching for some functions I'd may need).
...
I have a simple Google App Engine app, that I wrote using ordinary strings. I realize I want to make it handle unicode. Are there any gotchas with this? I'm thinking of all the strings that I currently already have in the live database. (From real users who I don't want to upset.)
...
When are objects or something else said to be "first class" in a given programming language, and why? In what do they differ from languages where they are not?
EDIT. When one says "everything is an object" (like in Python), does he indeed mean that "everything is first-class"?
...
I'd love a good native Python library to write XLS, but it doesn't seem to exist. Happily, Jython does.
So I'm trying to decide between jexcelapi and Apache HSSF:
http://www.andykhan.com/jexcelapi/tutorial.html#writing
http://poi.apache.org/hssf/quick-guide.html
(I can't use COM automation because I'm not on Windows, and even if I was...
which would you recommend?
which is faster, reliable?
apache mod_python or nginx/lighttpd FastCGI?
...
I feel like I should know this, but I haven't been able to figure it out...
I want to get the name of a method--which happens to be an integration test--from inside it so it can print out some diagnostic text. I can, of course, just hard-code the method's name in the string, but I'd like to make the test a little more DRY if possible.
...
Using Python I want to be able to draw text at different angles using PIL.
For example, imagine you were drawing the number around the face of a clock. The number 3 would appear as expected whereas 12 would we drawn rotated counter-clockwise 90 degrees.
Therefore, I need to be able to draw many different strings at many different angl...
I am building a simple Django app that will use scribd to display documents. I would like to have a page where the administrator can upload documents to scribd through the website, since I need to know a few things about it before it gets to scribd. What is the best/easiest way to do this, display an upload page and then take the file th...
This is rather the inverse of What can you use Python generator functions for?: python generators, generator expressions, and the itertools module are some of my favorite features of python these days. They're especially useful when setting up chains of operations to perform on a big pile of data--I often use them when processing DSV fil...
What would you use to perform a compliance testing of an HTTP proxy? I've seen two projects so far:
Web Polygraph (the feedback I got from a coworker is mostly negative)
Funkload
...
Im a coding a library inluding textual feedback that I need to translate.
I put the following lines in a _config.py module that I import everywhere in my app :
import gettext, os, sys
pathname = os.path.dirname(sys.argv[0])
localdir = os.path.abspath(pathname) + "/locale"
gettext.install("messages", localdir)
I have the *.mo files in...
I'm using Python's Imaging Library and I would like to draw some bezier curves.
I guess I could calculate pixel by pixel but I'm hoping there is something simpler.
...
When starting a django application using python manage.py shell, I get an InteractiveConsole shell - I can use tab completion, etc.
Python 2.5.1 (r251:54863, Apr 15 2008, 22:57:26)
[GCC 4.0.1 (Apple Inc. build 5465)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
When just starti...
I am creating a Python script where it does a bunch of tasks and one of those tasks is to launch and open an instance of Excel. What is the ideal way of accomplishing that in my script?
...
I want to detect whether module has changed. Now, using inotify is simple, you just need to know the directory you want to get notifications from.
How do I retrieve a module's path in python?
...
I have the following code in my Django application:
if 'book' in authorForm.changed_data:
#Do something here...
I realize Django can tell me which values have changed in my form by utilizing the "changed_data" list object, but I'd like to know the new values of the fields that have changed.
Any thoughts?
...
I'm developing an application that manages network interfaces on behalf of the user and it calls out to several external programs (such as ifconfig) that requires root to make changes. (Specifically, changing the IP address of a local interface, etc.) During development, I have been running the IDE as root (ugh) and the debugger as root ...
Recently I wrote a function to generate certain sequences with nontrivial constraints. The problem came with a natural recursive solution. Now it happens that, even for relatively small input, the sequences are several thousands, thus I would prefer to use my algorithm as a generator instead of using it to fill a list with all the sequen...
I have been trying to make a case for using Python at my work. We use C# and ASP.NET for basically all of our development. 80% or more of our projects are web applications. It seems natural that we would look at some of the nice dynamic web languages (Ruby, Python, etc), and with things like IronRuby and IronPython, I started seriously i...
'''use Jython'''
import shutil
print dir(shutil)
There is no, shutil.move, how does one move a file with Jython?
and while we at it, how does one delete a file with Jython?
...