Re: Instance vs Class variable oddity

2019-05-15 Thread Ben Finney
Irv Kalb writes: > I just saw some code that confused me. The confusion has to do with > class variables and instance variables. (Perhaps unrelated, but here's another confusion you may be suffering from: There's no such thing as a “class variable” or “instance variable”. In Python, a “variable

Re: Instance vs Class variable oddity

2019-05-15 Thread Irv Kalb
> On May 15, 2019, at 11:02 AM, Rob Gaddi > wrote: > > On 5/15/19 10:52 AM, Irv Kalb wrote: >> I just saw some code that confused me. The confusion has to do with class >> variables and instance variables. In order to understand it better, I built >> this very small example: >> class Test:

Can someone help me paral/accelerate this code for Cuda?

2019-05-15 Thread amoxletne5
It’s pretty darn slow. I don’t think it’s optimizing the Nvidia Tesla v100 power. It uses some openCv , and it just screams for paral/acceleration. I’d also love to learn and see how it’s done import cv2 import numpy as np import os import pickle import sys from cgls import cgls from filterplot

Re: Tkinter on Mac OS crashes python

2019-05-15 Thread Terry Reedy
On 5/15/2019 2:25 PM, Chip Towner wrote: Terry, Thanks for the input and FYI I am running 10.14.4 Mojave. When I looked at the version of tkinter as suggested by Chris Angelico earlier in this thread it returned '/Users/chip/anaconda3/lib/python3.6/tkinter/__init__.py’. This is obviously not

Re: Tkinter on Mac OS crashes python

2019-05-15 Thread Chris Angelico
On Thu, May 16, 2019 at 4:27 AM Chip Towner wrote: > > Terry, > Thanks for the input and FYI I am running 10.14.4 Mojave. When I looked at > the version of tkinter as suggested by Chris Angelico earlier in this thread > it returned '/Users/chip/anaconda3/lib/python3.6/tkinter/__init__.py’. Thi

Re: Tkinter on Mac OS crashes python

2019-05-15 Thread Chip Towner
Terry, Thanks for the input and FYI I am running 10.14.4 Mojave. When I looked at the version of tkinter as suggested by Chris Angelico earlier in this thread it returned '/Users/chip/anaconda3/lib/python3.6/tkinter/__init__.py’. This is obviously not he build Apple provided and I believe Appl

Re: Instance vs Class variable oddity

2019-05-15 Thread Rob Gaddi
On 5/15/19 10:52 AM, Irv Kalb wrote: I just saw some code that confused me. The confusion has to do with class variables and instance variables. In order to understand it better, I built this very small example: class Test: x = 0 def __init__(self, id): self.id = id

Instance vs Class variable oddity

2019-05-15 Thread Irv Kalb
I just saw some code that confused me. The confusion has to do with class variables and instance variables. In order to understand it better, I built this very small example: class Test: x = 0 def __init__(self, id): self.id = id self.show() def show(self):