On 16 Nov, 11:06, me not_h...@nowhere.com wrote:
What Python gui builder is well supported, does not require me
to learn another framework/library, and can crank out stuff for
multiple platforms ?
I use wxFormBuilder. The 3.1 beta can even create wxPython code, but
it still has some minor
On 16 Nov, 11:39, sturlamolden sturlamol...@yahoo.no wrote:
If you are fine with Microsoft only, you can use Windows Forms with MS
Visual Studio and IronPython.
I also forgot to mention:
If you can restrict yourself to Windows, you can always use Visual
Basic or Borland Delphi with pywin32
On 16 Nov, 10:06, Terry Reedy tjre...@udel.edu wrote:
Python run well on multiple cores, you just have to use processes
instead of threads.
But not so trivially as to add one word to an existing function.
Hence by tweak, I meant, as explained in another post, to add a keyword
or just a
On 16 Nov, 13:50, Kuhl chen_zhi...@yahoo.com wrote:
Python 2.2.3 (#1, Feb 2 2005, 12:22:48)
What's the mistake that I am making? How to solve it?
Your Python version is too old.
--
http://mail.python.org/mailman/listinfo/python-list
On 16 Nov, 14:25, Carl Banks pavlovevide...@gmail.com wrote:
Python can't call C function pointers.
Yes it can, use ctypes...
--
http://mail.python.org/mailman/listinfo/python-list
On 15 Nov, 15:30, mrholtsr mrhol...@gmail.com wrote:
I am absolutely new to python and barely past beginner in programming.
Also I am not a mathematician. Can some one give me pointers for
finding the 1000th. prime for a course I am taking over the internet
on Introduction to Computer Science
On 15 Nov, 17:05, Dietmar Schwertberger n...@schwertberger.de wrote:
Could you send me an .fbp file demonstrating the error?
Sent by email. Did you receive it?
No... could you please resend to stu...@molden.no?
--
http://mail.python.org/mailman/listinfo/python-list
On 15 Nov, 17:05, Dietmar Schwertberger n...@schwertberger.de wrote:
Sent by email. Did you receive it?
Yes I did, thank you :)
(I thought I didn't, but it was just a problem with my e-mail filter.)
--
http://mail.python.org/mailman/listinfo/python-list
On 14 Nov, 15:35, Dietmar Schwertberger n...@schwertberger.de wrote:
self.m_toolBar1 = self.CreateToolBar( wx.TB_HORIZONTAL, wx.ID_ANY )
self.m_button1 = wx.Button( self.m_toolBar1, wx.ID_ANY, uMyButton,
wx.DefaultPosition, wx.DefaultSize, 0 )
m_toolBar1.AddControl( m_button1 )
I
On 15 Nov, 05:21, Steven D'Aprano st...@remove-this-
cybersource.com.au wrote:
Psyco does JIT compilation to machine-code for CPython, at the cost of
much extra memory. It's also limited to 32-bit Intel processors. The aim
of the PyPy project is to (eventually) make JIT machine-code
On 16 Nov, 05:09, John Nagle na...@animats.com wrote:
Python is a very clean language held back from widespread use by slow
implementations. If Python ran faster, Go would be unnecessary.
That boggles me.
NASA can find money to build a space telescope and put it in orbit.
They don't
On 16 Nov, 05:09, John Nagle na...@animats.com wrote:
Python is a very clean language held back from widespread use by slow
implementations.
Python is clean, minimalistic, and beautiful.
Python don't have bloat like special syntax for XML or SQL databases
(cf C#) or queues (Go).
Most
On 15 Nov, 18:09, Peng Yu pengyu...@gmail.com wrote:
There had been some discussion on IDE. But I'm not sure what pros and
cons of each choice. Current, I'm using vim and ctags.
Could somebody give some advices on choosing the best IDE for me?
There is a plug-in to develop (amd debug) Python
On 14 Nov, 23:10, Terry Reedy tjre...@udel.edu wrote:
It would be much better, for instance, to tweak Python, which it
has had great success with, to better run on multiple cores.
Python run well on multiple cores, you just have to use processes
instead of threads.
--
On 12 Nov, 18:33, J Kenneth King ja...@agentultra.com wrote:
Where Python might get hit *as a language* is that the Python programmer
has to drop into C to implement optimized data-structures for dealing
with the kind of IO that would slow down the Python interpreter. That's
why we have
On 12 Nov, 18:32, Alf P. Steinbach al...@start.no wrote:
Of course Python is slow: if you want speed, pay for it by complexity.
Python is slow is really a misconception. Python is used for
scientific computing at HPC centres around the world. NumPy's
predecessor numarray was made by NASA for
On 12 Nov, 18:32, Alf P. Steinbach al...@start.no wrote:
Hm, this seems religious.
Of course Python is slow: if you want speed, pay for it by complexity.
Not really. The speed problems of Python can to a large extent be
attributed to a sub-optimal VM.
Perl tends to be much faster than
On 14 Nov, 09:47, Alf P. Steinbach al...@start.no wrote:
Python is slow is really a misconception.
Sorry, no, I don't think so.
No, i really think a lot of the conveived slowness in Python comes
from bad programming practices. Sure we can deomstrate that C or
LuaJIT is faster by orders of
On 12 Nov, 01:53, kj no.em...@please.post wrote:
I'm just learning about Google's latest: the GO (Go?) language.
(e.g.http://golang.orgorhttp://www.youtube.com/watch?v=rKnDgT73v8s).
There are some distinctly Pythonoid features to the syntax, such
as import this_or_that, the absence of
On 9 Nov, 05:49, Antony anthonir...@gmail.com wrote:
I just wanted to know which module is best for developing designing
interface in python .
I personally feel the wxPython support in the 3.1 beta of
wxFormBuilder makes the choise rather simple. It generates a Python
file with classes for
On 14 Nov, 15:35, Dietmar Schwertberger n...@schwertberger.de wrote:
self.m_toolBar1 = self.CreateToolBar( wx.TB_HORIZONTAL, wx.ID_ANY )
self.m_button1 = wx.Button( self.m_toolBar1, wx.ID_ANY, uMyButton,
wx.DefaultPosition, wx.DefaultSize, 0 )
m_toolBar1.AddControl( m_button1 )
On 14 Nov, 19:02, Dietmar Schwertberger n...@schwertberger.de wrote:
08/23/2009 Version 3.01.63 (Beta)
08/19/2009 Version 3.01.62 (Beta)
I tried 3.01.63.
I can see in the Python window already that the code is not correct.
3.01.63
Did you remember to install the wxAdditions?
Could you
On 14 Nov, 19:18, John Nagle na...@animats.com wrote:
Syntax for queues is a minor win.
No, that's syntax bloat.
The go keyword could be a problem as well. I suspect it could infringe
on Cilk++ patents. Perhaps Go cannot be used without a licence from
Cilk Arts?
--
On 14 Nov, 08:39, Robert Brown bbr...@speakeasy.net wrote:
Using Python 3 annotations, one can imagine a Python compiler that does the
appropriate thing (shown in the comments) with the following code.
I can imagine a lot too, but we're talking about Python as it's specified
*today*. The
On 6 Nov, 14:35, Alf P. Steinbach al...@start.no wrote:
As I understand it, 'is' will always work and will always be efficient (it
just
checks the variable's type), while '==' can depend on the implementation of
equality checking for the other operand's class.
'==' checks for logical
On 6 Nov, 18:28, Alf P. Steinbach al...@start.no wrote:
Dynamic allocation isn't hare-brained, but doing it for every stored integer
value outside a very small range is, because dynamic allocation is (relatively
speaking, in the context of integer operations) very costly even with a
On 6 Nov, 17:54, Alf P. Steinbach al...@start.no wrote:
But wow. That's pretty hare-brained: dynamic allocation for every stored value
outside the cache range, needless extra indirection for every operation.
First, integers are not used the same way in Python as they are in C+
+. E.g. you
On 14 Okt, 00:03, Steven D'Aprano
ste...@remove.this.cybersource.com.au wrote:
Obviously to run in O(log n) you must have already built the tree.
You don't need a tree. Quickselect is a partial quicksort.
But my memory served me badly, quickselect is O(n).
--
On 8 Okt, 09:17, Ulrich Eckhardt eckha...@satorlaser.com wrote:
I'm looking at the 'threading' module and see that other than the 'thread'
module it doesn't have a simple function to start a new thread. Instead,
you first have to instantiate a threading object and then start the new
thread on
On 2 Okt, 21:30, Dave Angel da...@ieee.org wrote:
There could very well be multiprocess support in wxPython. I'd check
there first, before re-inventing the wheel.
I don't think there is. But one can easily make a thread in the
subprocess that polls a pipe and calls wx.PostEvent or
On 2 Okt, 13:29, Dave Angel da...@ieee.org wrote:
Many people have concluded that (in Python) much of what threads are
used for should be done with processes.
Remember that threads were invented long before multi-core CPUs were
common. Java had threads before the VM could support more than one
On 2 Okt, 02:51, Aaron Hoover ahoo...@eecs.berkeley.edu wrote:
All the thread is doing most of the time is sitting around checking
the serial port for waiting data, reading it, and appending it to a
list when it finds it.
Do your threads ever block waiting for I/O? If they do, is the GIL
On 2 Okt, 20:19, Ole Streicher ole-usenet-s...@gmx.net wrote:
I *do* worry about speed. And I use Python. Why not? There are powerful
libraries available.
I do as well. But powerful libraries should release the GIL. Let me
rephrase that: I am not worried about speed in the part of my code
that
On 2 Okt, 22:29, Aaron Hoover ahoo...@eecs.berkeley.edu wrote:
My external hardware is actually sending 2000 packets per second right
now (but that can also be changed). Each packet currently contains 6
bytes of data and 6 bytes of overhead. So, 12 bytes per packet * 2000
packets per
On 2 Okt, 22:41, George Trojan george.tro...@noaa.gov wrote:
I have a problem with numpy's vectorize class and f2py wrapped old
FORTRAN code. I found that the function _get_nargs() in
site-packages/numpy/lib/function_base.py tries to find the number of
arguments for a function from an error
http://projects.scipy.org/numpy/ticket/1247
--
http://mail.python.org/mailman/listinfo/python-list
On 30 Sep, 19:03, Carl Banks pavlovevide...@gmail.com wrote:
Second, CObjects do not have a __del__ method. They call the supplied
constructor from the type's tp_dealloc slot. Use of the tp_dealloc
slot does not, by itself, prevent cyclic GC.
Bottom line is, the CObject's deallocator is as
On 29 Sep, 10:27, lallous lall...@lgwm.org wrote:
Hello
From my C extension module I want to store a C pointer in a given PyObject.
The only way I figure how to do it is to use Py_BuildValues and store the
poiner casted to Py_ssize_t,
Formally, you should cast the pointer to Py_intptr_t, as
On 29 Sep, 19:11, Carl Banks pavlovevide...@gmail.com wrote:
CObjects can be passed a C function as a deallocator; this should work
as reliably as a custom class deallocator.
Carl Banks
Except that __del__ prevents cyclic GC.
--
http://mail.python.org/mailman/listinfo/python-list
On 29 Sep, 23:56, Aaron Hoover ahoo...@eecs.berkeley.edu wrote:
how can I allow the thread
access to the connection for reading, but then have it give up control
over the connection when it's done so the main GUI thread can access
the connection again for writing?
Protect read/write
On 14 Sep, 00:05, Carl Banks pavlovevide...@gmail.com wrote:
Dice3DS works fine with PyOpenGL 3.x.
PyOpenGL is a bad idea anyway, due to the overhead of Python function
calls and ctypes. Doing 3D in pure Python at least requires NumPy
arrays as vertex arrays and/or extensive use of display
On 12 Sep, 15:54, Timothy Madden terminato...@gmail.com wrote:
I find that hard to believe, but I will look into it.
Carl Banks is correct.
There is a mutex called the global interpreter lock that takes care
of this. You can have multiple threads running, but access to the
Python interpreter
On 9 Sep, 22:28, Zac Burns zac...@gmail.com wrote:
Theories:
Python is resizing the large dictionary
Python is garbage collecting
Python uses reference counting, not a generational GC like Java. A
Python object is destroyed when the refcount drops to 0. The GC only
collects cyclic
On 10 Sep, 10:50, Hans Georg Schaathun ge...@ii.uib.no wrote:
Can anyone recommend a PRNG which supported multiple instances
with independent states, and that also can return numpy.array (or
something similar) efficiently?
numpy.random.RandomState
;-)
S.M.
--
On 9 Sep, 16:57, pdpi pdpinhe...@gmail.com wrote:
Raising this to 1 million, rather than 100, nodes in the window, the
timing difference between your version and NumPy's is tiny (but numpy
still edges you out, but just barely), but they trounce my naive
version, being around 7 or 8 times
On 8 Sep, 04:22, ganesh ganeshbo...@gmail.com wrote:
My application is a TCP server having multiple client connectons. C++
PTHREADS are for each connected socket and the message received on the
socket is evaluated by python functions.
If I use only one process level python interpreter, then
On 8 Sep, 08:46, I V ivle...@gmail.com wrote:
Do you have to use threads? If you use a process per connection, rather
than a thread, each process will have its own GIL.
If ganesh is using Linux or Unix (which pthreads indicate), fork() is
just as efficient as threads.
On Windows one would
On 8 Sep, 09:14, ganesh ganeshbo...@gmail.com wrote:
No, i cannot change from threads to processes for handling
connections. This will change the complete design of our application
which is not feasilbe for python evaluation of the strings.
So the problem is actually bad design?
--
On 8 Sep, 13:36, Pierre pierre.gaill...@gmail.com wrote:
anyone knows what is the python equivalent of the matlab's hanning
function.
Note that in matlab hann and hanning are different.
If you don't know how to compute a von Hann window, you are not
competent to do any scientific
On 8 Sep, 15:08, pdpi pdpinhe...@gmail.com wrote:
Come, come. I think it's a good rule that, where available, a vendor-
supplied implementation is the preferable choice until proven
otherwise.
Even for the simplest of equations?
--
http://mail.python.org/mailman/listinfo/python-list
On 9 Sep, 00:24, Steven D'Aprano
ste...@remove.this.cybersource.com.au wrote:
A decent vendor-supplied implementation will include error checking that
you otherwise would need to implement yourself, so yes.
Not for code like this:
import numpy as np
n = np.arange(101)
w =
On 9 Sep, 03:45, hi_roger rechardc...@gmail.com wrote:
hello, i want to ask a question about numpy.
i know how to select a submatrix using the slice object in numpy. But
how can i select a submatrix
A[i1,i2,i3;j1,j2,j3] (elements in A on line i1,i2,i3 and column
j1,j2,j3 , and
On 9 Sep, 03:45, hi_roger rechardc...@gmail.com wrote:
i know how to select a submatrix using the slice object in numpy. But
how can i select a submatrix
A[i1,i2,i3;j1,j2,j3] (elements in A on line i1,i2,i3 and column
j1,j2,j3 , and i1,i2,i3,j1,j2,j3 are all arbitrary numbers )
You just
On 7 Sep, 07:17, grbgooglefan ganeshbo...@gmail.com wrote:
Can we not use python interpreters even private to each multiple
thread?
You can use multiple interpreters, but they share GIL. For example,
Python extension modules are DLLs and will be loaded only once for
each process - the OS makes
On 7 Sep, 07:59, ganesh ganeshbo...@gmail.com wrote:
No, I did not use GIL.
-- For using GIL, do we need to initialize GIL at startup and destroy/
finalize it at end?
-- Are there any configuration build related flags that I need to
use to make this work?
Please guide. Thanks.
I just
On 7 Sep, 13:53, ganesh ganeshbo...@gmail.com wrote:
I need to use these to get the proper concurrency in my multi-threaded
application without any synchronization mechanisms.
Why will multiple interpreters give you better concurrency? You can
have more than one thread in the same interpreter.
On 7 Sep, 13:17, Ulrich Eckhardt eckha...@satorlaser.com wrote:
Quoting from above: The GIL is global to the process. So no, it is NOT
private to each thread which means python isn't either.
At least that is my understanding of the issue.
Strictly speaking, the GIL is global to the Python
On 7 Sep, 14:50, MRAB pyt...@mrabarnett.plus.com wrote:
CPython's GIL means that multithreading on multiple processors/cores has
limitations. Each interpreter has its own GIL, so processor-intensive
applications work better using the multiprocessing module than with the
threading module.
We
On 7 Sep, 07:17, grbgooglefan ganeshbo...@gmail.com wrote:
What is best way to embed python in multi-threaded C++ application?
Did you remeber to acquire the GIL? The GIL is global to the process
(hence the name).
void foobar(void)
{
PyGILState_STATE state = PyGILState_Ensure();
/*
On 5 Sep, 08:47, Steven D'Aprano st...@remove-this-
cybersource.com.au wrote:
How do you know?
After more than 10 years experience with scientific programming I just
do. When it comes to numerics I have a gut feeling for what is fast
and what is slow.
It's not difficult actually. You just have
On 4 Sep, 06:20, John Nagle na...@animats.com wrote:
In the current CPython implementation, every object has a reference
count, even immutable ones. This must be a writable field - and here you
have your race condition, even for immutable objects.
That's an implementation problem with
On 3 Sep, 20:03, John Nagle na...@animats.com wrote:
Python doesn't have immutable objects as a general concept, but
it may be headed in that direction. There was some fooling around
with an immmutability API associated with NumPy back in 2007, but
that was removed. As more immutable
On 5 Sep, 05:12, Steven D'Aprano st...@remove-this-
cybersource.com.au wrote:
Is the difference because of mutability versus immutability, or because
of C code in Numpy versus Matlab code? Are you comparing bananas and
pears?
It consisted of something like this
import numpy
def
On 4 Sep, 14:50, Michele Simionato michele.simion...@gmail.com
wrote:
# requires byteplay by Noam Raphael
# seehttp://byteplay.googlecode.com/svn/trunk/byteplay.py
from byteplay import Code, LOAD_GLOBAL, STORE_FAST, LOAD_FAST
Incrediby cool :-)
--
On 5 Sep, 07:04, Steven D'Aprano st...@remove-this-
cybersource.com.au wrote:
Your code does a lot of unnecessary work if you're just trying to
demonstrate immutability is faster or slower than mutability.
No ... I was trying to compute D4 wavelet transforms. I wanted to see
how NumPy compared
On 5 Sep, 07:04, Steven D'Aprano st...@remove-this-
cybersource.com.au wrote:
How does Matlab speed compare to Python in general?
Speed-wise Matlab is slower, but it is not the interpreter limiting
the speed here.
--
http://mail.python.org/mailman/listinfo/python-list
On 28 Aug, 02:34, Deep_Feelings doctore...@gmail.com wrote:
python got relatively fewer numbers of developers than other high
level languages like .NET , java .. etc why ?
Because we are better, so fewer are needed.
--
http://mail.python.org/mailman/listinfo/python-list
On 26 Aug, 22:47, David C Ullrich dullr...@sprynet.com wrote:
Nothing, except lobbying for wxFormBuilder for anyone who still doesn't
know of it. :)
That's great. But do you know of anything I can use as a
visual form design tool in wxPython?
Right... I don't know if you are trying to be
On 25 Aug, 13:33, Piet van Oostrum p...@cs.uu.nl wrote:
I have heard about that also, but is there a Python implementation that
uses this? (Just curious, I am not using Windows.)
On Windows we have three different versions of Python 2.6:
* Python 2.6 for Win32/64 (from python.org) does not
On 25 Aug, 17:37, Matjaz Bezovnik mbezov...@freenet.si wrote:
Scott, thank you very much for the snippet.
It is exactly what I looked for; simple to read and obvious as to what
it does even a month later to a non-pythonist!
Since you were talking about matrices, observe that numpy has a
On 25 Aug, 20:30, Gilles Ganault nos...@nospam.com wrote:
Combined with the comment above about issues with printing, it looks
like Python for GUI apps isn't a very good idea :-/
With pywin32, printing is the same as for any other Windows app (you
get MFC for Python).
--
On 25 Aug, 13:24, Wolfgang Keller felip...@gmx.net wrote:
The area of _desktop_ database application development indeed looks like a
vast and very hostile desert in the Python landscape.
Yes, you don't have drag-and-drop database tools like MS Access or
FoxPro. You actually have to use a
On 25 Aug, 21:45, Terry Reedy tjre...@udel.edu wrote:
Will be good news if realized.
Good news for everyone except Riverbank.
--
http://mail.python.org/mailman/listinfo/python-list
On 24 Aug, 10:24, n...@cam.ac.uk wrote:
In article 5134d9f1-0e23-4e05-a817-bf0cc9e85...@w6g2000yqw.googlegroups.com,
sturlamolden sturlamol...@yahoo.no wrote:
On 24 Aug, 02:26, nos...@see.signature (Richard Maine) wrote:
You missed the word OOP, which seemed like the whole point
On 18 Aug, 22:10, Derek Martin c...@pizzashack.org wrote:
I have some simple threaded code... If I run this
with an arg of 1 (start one thread), it pegs one cpu, as I would
expect. If I run it with an arg of 2 (start 2 threads), it uses both
CPUs, but utilization of both is less than 50%.
On 24 Aug, 13:21, Piet van Oostrum p...@cs.uu.nl wrote:
But os.fork() is not available on Windows. And I guess refcounts et al.
will soon destroy the sharing.
Well, there is os.fork in Cygwin and SUA (SUA is the Unix subsytem in
Windows Vista Professional). Cygwin's fork is a bit sluggish.
On 24 Aug, 14:08, Gilles Ganault nos...@nospam.com wrote:
I'm especially concerned about the lack of controls, the lack of
updates (lots of controls in wxWidgets are 1.0 deadware), and problems
linked to how to update users' PC remotely when I build a new version
using eg. Py2exe.
There is
On 24 Aug, 14:08, Gilles Ganault nos...@nospam.com wrote:
and problems
linked to how to update users' PC remotely when I build a new version
using eg. Py2exe.
Remote update is a problem regardless of language. It typically
involves the following steps:
1. Download the update from a server
On 24 Aug, 18:20, n...@cam.ac.uk wrote:
This obviosuly proves you wrong:
Er, no, it doesn't. I suggest that you read what I said more
carefully - and the Fortran standard. As I said, you can kludge
them up, and that is precisely one such kludge -
You said we have to kludge them up as
On 24 Aug, 20:55, n...@cam.ac.uk wrote:
Precisely. And the kludge does NOT work under all circumstances,
which is why I said that it doesn't work very well.
Do you have an example?
Consider, for example:
SUBROUTINE Fred (X) BIND(C)
CHARACTER*(*) :: X
END SUBROUTINE Fred
On 24 Aug, 21:24, n...@cam.ac.uk wrote:
You might also like to consider the converse problem: how to write
a Fortran function that takes a C string of arbitrary length and
uses it.
That's what the code I showed you does.
--
http://mail.python.org/mailman/listinfo/python-list
On 25 Aug, 01:26, Piet van Oostrum p...@cs.uu.nl wrote:
That's because it doesn't use copy-on-write. Thereby losing most of its
advantages. I don't know SUA, but I have vaguely heard about it.
SUA is a version of UNIX hidden inside Windows Vista and Windows 7
(except in Home and Home Premium),
On 25 Aug, 03:51, Peter Decker pydec...@gmail.com wrote:
I've used in fairly regularly for about 2 years now. I haven't had to
write that ugly wxPython code for so long that every time I see
examples on their mail list I wanna barf.
I prefer wxFormBuilder. GUIs should be designed visually
On 25 Aug, 05:56, Peter Decker pydec...@gmail.com wrote:
I use the Dabo Class Designer to visually design my forms. So what's
you're point? :)
Nothing, except lobbying for wxFormBuilder for anyone who still
doesn't know of it. :)
--
http://mail.python.org/mailman/listinfo/python-list
On 23 Aug, 12:35, n...@cam.ac.uk wrote:
I am interested in surveying people who want to interoperate between
Fortran and Python to find out what they would like to be able to do
more conveniently, especially with regard to types not supported for C
interoperability by the current Fortran
On 23 Aug, 20:42, n...@cam.ac.uk wrote:
That is precisely what I am investigating. TR 29113 falls a LONG
way before it gets to any of the OOP data - indeed, you can't even
pass OOP derived types as pure data (without even the functionality)
in its model. Nor most of what else Python would
On 24 Aug, 00:02, Dennis Lee Bieber wlfr...@ix.netcom.com wrote:
That's a C language problem -- since a string in C is just an array
of character. The last FORTRAN dialect (and implementation) I used
passed strings
On 24 Aug, 00:02, Dennis Lee Bieber wlfr...@ix.netcom.com wrote:
On 24 Aug, 01:59, sturlamolden sturlamol...@yahoo.no wrote:
subroutine foobar(cstr) bind(c, name='foobar')
use, intrinsic :: iso_c_binding
type(c_ptr) :: cstr
character(*), pointer :: fstr
call c_f_pointer(cptr, fptr)
Which means that you can write a wrapper in Fortran
On 24 Aug, 02:26, nos...@see.signature (Richard Maine) wrote:
You missed the word OOP, which seemed like the whole point. Not that
the particular word is used in the Fortran standard, but it isn't hard
to guess that he means a derived type that uses some of the OOP
features. Inheritance,
On 24 Aug, 01:59, sturlamolden sturlamol...@yahoo.no wrote:
subroutine foobar(cstr) bind(c, name='foobar')
use, intrinsic :: iso_c_binding
type(c_ptr) :: cstr
character(*), pointer :: fstr
call c_f_pointer(cptr, fptr)
Actually, this does not work, as it is illegal to create
On 24 Aug, 02:57, nos...@see.signature (Richard Maine) wrote:
Yes, it is no surprise that the C interop stuff fails to address this,
since it isn't in C. Something different/extra would be needed, which is
exactly what Nick said. I'm going to jump out of the middle of this now.
The only
On 23 Aug, 21:59, Emile van Sebille em...@fenx.com wrote:
Speed of what? Development? User interaction? Responsiveness to queries?
My personal view on the 'Is Python faster than Java' question:
- Coding? Yes, if you program 'pythonic'.
- String handling? Often.
- I/O and networking? Often.
On 19 Aug, 20:22, laser laser.y...@gmail.com wrote:
In the future, will Python provide programe enviroment like Maple
does?
You might be looking for SAGE.
http://www.sagemath.org/
--
http://mail.python.org/mailman/listinfo/python-list
On 19 Aug, 01:48, Pierre pierre.gaill...@gmail.com wrote:
Well, the equivalence of setdiff in matlab...
That would be numpy.setdiff1d.
--
http://mail.python.org/mailman/listinfo/python-list
On 18 Aug, 11:19, Robert Dailey rcdai...@gmail.com wrote:
I'm looking for a way to parallelize my python script without using
typical threading primitives. For example, C++ has pthreads and TBB to
break things into tasks.
In C++, parallelization without typical threading primitives usually
On 18 Aug, 13:45, Robert Dailey rcdai...@gmail.com wrote:
Really, all I'm trying to do is the most trivial type of
parallelization. Take two functions, execute them in parallel. This
type of parallelization is called embarrassingly parallel, and is
the simplest form. There are no dependencies
On 19 Aug, 05:16, sturlamolden sturlamol...@yahoo.no wrote:
You should know about the GIL. It prevents multiple threads form using
the Python interpreter simultaneously. For parallel computing, this is
a blessing and a curse. Only C extensions can release the GIL; this
includes I/0 routines
On 19 Aug, 05:27, Dave Angel da...@ieee.org wrote:
With the current GIL implementation, for two CPU-bound tasks, you either
do them sequentially, or make a separate process.
I'd also like to add that most compute-bound code should be delegated
to specialized C libraries, many of which are
On 19 Aug, 05:34, Hendrik van Rooyen hend...@microcorp.co.za wrote:
The GIL does apply - I was talking nonsense again. Misread the OP's
intention.
It depends on what the OP's functions doStuff1 and doStuff2
actually do. If they release the GIL (e.g. make I/O calls) it does not
apply. The GIL
On 18 Aug, 11:41, Stefan Behnel stefan...@behnel.de wrote:
I think the canonical answer is to use the threading module or (preferably)
the multiprocessing module, which is new in Py2.6.
http://docs.python.org/library/threading.htmlhttp://docs.python.org/library/multiprocessing.html
Both
201 - 300 of 771 matches
Mail list logo