Re: polar coordinates?

2018-12-18 Thread Brian Christiansen
I don't think what I am currently doing is heat maps, but at least from what I have read, they could be adapted to "visualiztions of PI." Toward that end I decided to put a link to the video that inspired me, a link to where I got the graphics.py package (or at least where I think I got it), a

Re: setup.py, how to find main program/module?

2018-12-18 Thread dieter
ant writes: > ... > yet not quite all the way yet. i run the > commands to make the sdist and wheels and upload > it using twine to my test account, but when > i install it and try to run it the ngfp.py is > not found (i've also tried nfgp and main). > ... > i suspect i've not really underst

Mask two images with python

2018-12-18 Thread Umar Yusuf
Hello there, How do I supper impose an image design on a transparent png image? I have tried to use OpenCV's "cv2.bitwise_and" function to no success. I posted the detail question here: https://stackoverflow.com/questions/53791510/python-opencv-mask-and-glow Thank you for your time. -- https:/

setup.py, how to find main program/module?

2018-12-18 Thread ant
hello, i'm getting there... yet not quite all the way yet. i run the commands to make the sdist and wheels and upload it using twine to my test account, but when i install it and try to run it the ngfp.py is not found (i've also tried nfgp and main). test upload: https://test.pypi.or

Re: Python, the stack, and the heap

2018-12-18 Thread eryk sun
On 12/17/18, Chris Angelico wrote: > > Hang on, you're conflating two different things here. You're probably right that I misinterpreted what the OP meant by references winding up "on the stack". It's more common for a Python developer to think of the call stack instead of the implementation deta

RE: Complex 'compare'

2018-12-18 Thread Avi Gross
Frank, Thanks for explaining. It looks like you might want a shortcut compare done in an iterative or recursive way that returns as soon as a discrepancy happens in the direction you are comparing. If they are equal, you fall off the end. A pythonic way is to use a loop as in: >>> flag = True >

Re: Why do data descriptors (e.g. properties) take priority over instance attributes?

2018-12-18 Thread Ian Kelly
On Mon, Dec 17, 2018, 12:09 PM Paul Baker When Python looks up an attribute on an object (i.e. when it executes > `o.a`), it uses an interesting priority order [1]. It looks for: > > 1. A class attribute that is a data-descriptor (most commonly a property) > 2. An instance attribute > 3. Any ot

RE: Complex 'compare'

2018-12-18 Thread Avi Gross
Frank, I am not commenting on your specific code, just asking a question. If you have two tuples of the same size it does seem that python evaluates them in the order you want just by doing something like this example I made with a 2-tuple: >>> (1, 2) > (2,1) False >>> (1, 2) > (1,1) True >>> (1

Re: How to use multiple instances of the same COM object at the same time

2018-12-18 Thread h . kheti . serpentcs
On Friday, March 22, 2013 at 11:43:50 PM UTC+5:30, Jan wrote: > Dear Usenet readers, > > Our company wants to implement about 40 biometric access control devices > which have a proprietary DLL with a COM object in it. > > I've done some research about COM objects and how to use them. > Now, I ne

Re: Complex 'compare'

2018-12-18 Thread Frank Millman
"Chris Angelico" wrote in message news:CAPTjJmpLuyFf04AT+34VraJ5itDvNySVJspEv=ddwdsmmsf...@mail.gmail.com... On Tue, Dec 18, 2018 at 9:52 PM Frank Millman wrote: > I need to know if one row is greater than or less than the other. The > sort > sequence can be complex - one or more columns, eac

Re: Complex 'compare'

2018-12-18 Thread Chris Angelico
On Tue, Dec 18, 2018 at 9:52 PM Frank Millman wrote: > I need to know if one row is greater than or less than the other. The sort > sequence can be complex - one or more columns, each of which can be sorted > ascending or descending. > > Below is the function I have come up with. Can anyone see an

Complex 'compare'

2018-12-18 Thread Frank Millman
Hi all I want to compare two tuples. They each represent a row in a database, and each element represents a column, so I will use that terminology. I need to know if one row is greater than or less than the other. The sort sequence can be complex - one or more columns, each of which can be so

Re: ipython does not work with latest version of prompt-toolkit

2018-12-18 Thread banerjee . rohan98
On Sunday, 3 June 2018 13:58:14 UTC+5:30, Cecil Westerhof wrote: > When executing: > pip3 list --no-cache-dir --outdated > > I got: > prompt-toolkit 1.0.152.0.1wheel > PyGObject 3.28.23.28.3 sdist > youtube-dl 2018.5.30 2018.6.2 wheel > > So I executed: >

Re: Why do data descriptors (e.g. properties) take priority over instance attributes?

2018-12-18 Thread dieter
Paul Baker writes: > When Python looks up an attribute on an object (i.e. when it executes > `o.a`), it uses an interesting priority order [1]. It looks for: > > 1. A class attribute that is a data-descriptor (most commonly a property) > 2. An instance attribute > 3. Any other class attribute >

Re: Variable number of arguments

2018-12-18 Thread dieter
F Massion writes: > My script is used by a web interface which gets some parameters from a form. > The parameters are passed on as arguments like this: > > (...) > def start(self, _Inputfile ,_Outputfile ,_Stopwordsfile) > > As long as the number of arguments is set (i.e. 3), there are no problems

Re: pickle and module versioning

2018-12-18 Thread dieter
Neal Becker writes: > ... > Has anyone else run into this issue People who use the "ZODB" (= "Zope Object DataBase") are familiar with it. > and have any ideas? There are things, you must not do. In the "ZODB" case, for example, you must not change whether the class inherits from "persistent.Pe