chatterbot -ML

2018-03-07 Thread harirammanohar159
Hi, Entire chatterbot we feed the bot with data and it responds accordingly. But why they say its a machine learning dialogue conversation. i dont see any machine learning in that. Atleast if bot doesnt have data what user speaks, if it learns and speaks next time then we can accept machine le

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread dieter
C W writes: > I am new to OOP. I'm a bit confused about the following code. > > class Clock(object): > def __init__(self, time): > self.time = time > def print_time(self): > time = '6:30' > print(self.time) > > clock = Clock('5:30') > clock.print_time() > 5:30 > > I

Module Issue

2018-03-07 Thread Abdur-Rahmaan Janhangeer
i have a project at https://github.com/Abdur-rahmaanJ/honeybot see https://github.com/Abdur-rahmaanJ/honeybot/tree/master/honeybot my question is : how to include a util file / module that can be imported in both core_plugins and user_plugins? if that is too difficult, let us take only core_pl

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread Frank Millman
"C W" wrote in message news:cae2fw2nudjcmvukavzh01trkqeentkdxdpbawcphhsgx8jv...@mail.gmail.com... Hello, I am new to OOP. I'm a bit confused about the following code. class Clock(object): def __init__(self, time): self.time = time def print_time(self): time = '6:30'

Re: LXML: can't register namespace

2018-03-07 Thread Andrew Z
help(etree.register_namespace) Help on cython_function_or_method in module lxml.etree: register_namespace(prefix, uri) Registers a namespace prefix that newly created Elements in that namespace will use. The registry is global, and any existing mapping for either the given prefix or th

Futurize maps StringIO.StringIO to io.StringIO

2018-03-07 Thread Skip Montanaro
I had some deja vu recently, cuz of this old thread: https://mail.python.org/pipermail/python-list/2013-May/648245.html Today the context is different, but the problem remains the same. One of the futurize refactoring tools converts usage of StringIO.StringIO to io.StringIO, which, given that the

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread Dan Sommers
On Wed, 07 Mar 2018 16:57:51 -0500, C W wrote: > class Clock(object): > def __init__(self, time): > self.time = time > def print_time(self): > time = '6:30' > print(self.time) > > clock = Clock('5:30') > clock.print_time() > 5:30 > > I set time to 6:30, but it's c

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread Dan Sommers
On Wed, 07 Mar 2018 16:57:51 -0500, C W wrote: > Hello, > > I am new to OOP. I'm a bit confused about the following code. > > class Clock(object): > def __init__(self, time): > self.time = time > def print_time(self): > time = '6:30' > print(self.time) > > clock

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread Dan Stromberg
On Wed, Mar 7, 2018 at 1:57 PM, C W wrote: > I set time to 6:30, but it's coming out to 5:30. I guess it's because I > passed in 5:30, so, it's replaced? time and self.time are 2 different things. > How does line-by-line execution run inside a frame To quickly come to grips with execution order

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread Cameron Simpson
On 07Mar2018 16:57, C W wrote: I am new to OOP. I'm a bit confused about the following code. class Clock(object): def __init__(self, time): self.time = time def print_time(self): time = '6:30' print(self.time) clock = Clock('5:30') clock.print_time() 5:30 I set time

what is the best qr package

2018-03-07 Thread Subramanian P V
what is the best qr package -- https://mail.python.org/mailman/listinfo/python-list

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread Terry Reedy
On 3/7/2018 4:57 PM, C W wrote: Hello, I am new to OOP. I'm a bit confused about the following code. class Clock(object): def __init__(self, time): self.time = time def print_time(self): time = '6:30' print(self.time) Local name 'time' is bound to '6:30'.

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread Ben Finney
C W writes: > I am new to OOP. Welcome, and congratulations on learning Python. > I'm a bit confused about the following code. > > def print_time(self): Begins a function definition. The function will receive one argument (the class instance), and bind the name ‘self’ to that. >

Re: csv module and NULL data byte

2018-03-07 Thread John Pote
On 07/03/2018 07:59, Andrew McNamara wrote: Last time I read the documentation, it was recommended that the file be opened in BINARY mode ("rb"). It recommends binary mode, but seems to largely work fine with text/ascii mode or even arbitrary iterables. I've not seen the rationale behin

Re: How to make Python run as fast (or faster) than Julia

2018-03-07 Thread Python
On Thu, Mar 08, 2018 at 08:44:16AM +1100, Chris Angelico wrote: > On Thu, Mar 8, 2018 at 8:36 AM, Python wrote: > > On Mon, Mar 05, 2018 at 04:09:48PM -0800, Dan Stromberg wrote: > >> On Mon, Mar 5, 2018 at 3:53 PM, Python wrote: > >> > On Sat, Mar 03, 2018 at 08:18:03AM +1100, Chris Angelico wro

Re: Which part of the loop is it going through in this class frame?

2018-03-07 Thread jladasky
On Wednesday, March 7, 2018 at 1:58:33 PM UTC-8, C W wrote: > Hello, > > I am new to OOP. There are (at least) two purposes for classes: 1) To group together data and functions in a meaningful way. Functions which are defined inside a class are called methods. 2) To allow the preservation of

Which part of the loop is it going through in this class frame?

2018-03-07 Thread Youta TAKAOKA
When we want to set attributes of `self`, we should do it explicitly. Not like `this.` in java or C#, `self.` is needed in python. So, the method > def print_time(self): > time = '6:30' > print(self.time) does 1. set a local variable `time` as '6:30' 2. print `time` which is an

Which part of the loop is it going through in this class frame?

2018-03-07 Thread C W
Hello, I am new to OOP. I'm a bit confused about the following code. class Clock(object): def __init__(self, time): self.time = time def print_time(self): time = '6:30' print(self.time) clock = Clock('5:30') clock.print_time() 5:30 I set time to 6:30, but it's co

Re: How to make Python run as fast (or faster) than Julia

2018-03-07 Thread Chris Angelico
On Thu, Mar 8, 2018 at 8:36 AM, Python wrote: > On Mon, Mar 05, 2018 at 04:09:48PM -0800, Dan Stromberg wrote: >> On Mon, Mar 5, 2018 at 3:53 PM, Python wrote: >> > On Sat, Mar 03, 2018 at 08:18:03AM +1100, Chris Angelico wrote: >> >> > Python is often a preferred solution because it is often fan

Re: How to make Python run as fast (or faster) than Julia

2018-03-07 Thread Python
On Mon, Mar 05, 2018 at 04:09:48PM -0800, Dan Stromberg wrote: > On Mon, Mar 5, 2018 at 3:53 PM, Python wrote: > > On Sat, Mar 03, 2018 at 08:18:03AM +1100, Chris Angelico wrote: > >> > Python is often a preferred solution because it is often fantastic for > >> > rapid implementation and maintaina

Re: Console

2018-03-07 Thread eryk sun
On Wed, Mar 7, 2018 at 7:59 PM, bartc wrote: > On 07/03/2018 15:34, Wolfgang Maier wrote: >> >> On 03/07/2018 03:41 PM, Jeremy Jamar St. Julien wrote: >>> >>> I had an problem when trying to start the python GUI. It said there was a >>> subprocess startup error. I was told to start IDLE in a conso

Re: Console

2018-03-07 Thread bartc
On 07/03/2018 15:34, Wolfgang Maier wrote: On 03/07/2018 03:41 PM, Jeremy Jamar St. Julien wrote: I had an problem when trying to start the python GUI. It said there was a subprocess startup error. I was told to start IDLE in a console with idlelib and see what python binary i was runnning IDLE

Re: RFC: Proposal: Deterministic Object Destruction (Posting On Python-List Prohibited)

2018-03-07 Thread Chris Angelico
On Thu, Mar 8, 2018 at 5:17 AM, Ooomzay wrote: > On Thursday, 1 March 2018 22:44:59 UTC, Rob Gaddi wrote: >> On 03/01/2018 02:24 PM, Lawrence D’Oliveiro wrote: >> > On Thursday, March 1, 2018 at 6:44:39 PM UTC+13, Paul Rubin wrote: >> >> DOM trees are a classic example (see the various DOM module

Re: RFC: Proposal: Deterministic Object Destruction (Posting On Python-List Prohibited)

2018-03-07 Thread Ooomzay
On Thursday, 1 March 2018 22:44:59 UTC, Rob Gaddi wrote: > On 03/01/2018 02:24 PM, Lawrence D’Oliveiro wrote: > > On Thursday, March 1, 2018 at 6:44:39 PM UTC+13, Paul Rubin wrote: > >> DOM trees are a classic example (see the various DOM modules in the > >> Python stdlib). Non-leaf nodes have a

Re: Console

2018-03-07 Thread Jeremy Jamar St. Julien
I think i fixed the problem for now. When i tried to run programs it was giving me errors in certain prewritten python files so i wiped them all and redownloaded them from the website - Original Message - From: "Rhodri James" To: python-list@python.org Sent: Wednesday, March 7, 2018 8:5

Re: Console

2018-03-07 Thread eryk sun
On Wed, Mar 7, 2018 at 2:41 PM, Jeremy Jamar St. Julien wrote: > I had an problem when trying to start the python GUI. It said there was a > subprocess startup > error. I was told to start IDLE in a console with idlelib and see what python > binary i was > runnning IDLE with. Im using windows 10

Re: Console

2018-03-07 Thread Wolfgang Maier
On 03/07/2018 03:41 PM, Jeremy Jamar St. Julien wrote: I had an problem when trying to start the python GUI. It said there was a subprocess startup error. I was told to start IDLE in a console with idlelib and see what python binary i was runnning IDLE with. Im using windows 10 and i guess cons

Re: Console

2018-03-07 Thread Rhodri James
On 07/03/18 14:41, Jeremy Jamar St. Julien wrote: I had an problem when trying to start the python GUI. It said there was a subprocess startup error. I was told to start IDLE in a console with idlelib and see what python binary i was runnning IDLE with. Im using windows 10 and i guess console r

Console

2018-03-07 Thread Jeremy Jamar St. Julien
I had an problem when trying to start the python GUI. It said there was a subprocess startup error. I was told to start IDLE in a console with idlelib and see what python binary i was runnning IDLE with. Im using windows 10 and i guess console refers to the terminal window and i have no idea wha

Re: Python 3.6

2018-03-07 Thread Rhodri James
On 07/03/18 14:07, Jeremy Jamar St. Julien wrote: How do i open python 3.6 in a console and how do i see the binary its running with Can you give us a little more information? What operating system are you using? When you say "console", do you mean whatever passes for a terminal window on

Python 3.6

2018-03-07 Thread Jeremy Jamar St. Julien
How do i open python 3.6 in a console and how do i see the binary its running with -- https://mail.python.org/mailman/listinfo/python-list

Re: LXML: can't register namespace

2018-03-07 Thread Andrew Z
Yes, if i give it any non empty tag - all goes well. All im trying to do is to extract a namespace ( i try to keep simple here. Just first one for now) and register it so i can save xml later on. On Mar 7, 2018 00:38, "Steven D'Aprano" < steve+comp.lang.pyt...@pearwood.info> wrote: > On Tue, 06

Re: Python installer hangs in Windows 7

2018-03-07 Thread eng . laio
Hi! Exact same problem here! Stucked at "initializing setup", windows 7, pyhton 3.6.4, etc, etc, etc However, while looking for solutions on the internet.. guess who's decided to come to party??? Setup finally started! I guess we just have to be pacient and give its time... -- https://mail

Re: csv module and NULL data byte

2018-03-07 Thread Andrew McNamara
>> Last time I read the documentation, it was recommended that >> the file be opened in BINARY mode ("rb"). > >It recommends binary mode, but seems to largely work fine with >text/ascii mode or even arbitrary iterables. I've not seen the >rationale behind the binary recommendation, but in 10+