data sequencing

2020-01-31 Thread khishorks
I have a data sequence of around 30 sets. I need to batch the sequence into an input-output format. for example data= [1,2,3,4,5,6,7,8,9,10,..,100] X1= [1,2,3,4,5,6,7,8,9,10] y1 = [11,12] X2= [3,4,5,6,7,8,9,11,12] y2 = [13,14] and it continues till 100. here X is input and y is o

Re: Please answer fast.....

2020-01-31 Thread DL Neil via Python-list
On 1/02/20 1:05 AM, Souvik Dutta wrote: Hi, This is problem from pyqt5. Actually I want to have about 40 labels added into a window when a button is clicked. The text are not the same so the label is not the same. I cannot just add 40 labels before hand and then change its text to something from

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread DL Neil via Python-list
On 31/01/20 9:53 PM, R.Wieser wrote: Using ctrl+c is a VERY BAD idea. To have it just exit the program ? Yes, indeed. Though you /could/ keep track of what needs to be finished and have the ctrl-c handler do that for you (barf). Another posibility is to capture the ctrl-c and set a flag, whi

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread DL Neil via Python-list
On 31/01/20 9:30 AM, jkn wrote: Err, well, thanks for that discussion gents... As it happens I do know how to use a database, but I regard it as overkill for what I am trying to do here. I think a combination of hashing the URL, and using a suffix to indicate the result of previous downloaded at

Re: QTableWidget help!!

2020-01-31 Thread Barry
> On 31 Jan 2020, at 03:38, Souvik Dutta wrote: > > Hi, > I want to add a QTableWidget to an existing window with other labels and > button. How can I add the QTableWidget without having to set it as > centralwidget and be able to move it and set geometry. Because I am not > being able to move

Re: QTableWidget help!!

2020-01-31 Thread Abdur-Rahmaan Janhangeer
QTableView is recommended, what pyqt version are you using? On Fri, 31 Jan 2020, 07:35 Souvik Dutta, wrote: > Hi, > I want to add a QTableWidget to an existing window with other labels and > button. How can I add the QTableWidget without having to set it as > centralwidget and be able to move it

Please answer fast.....

2020-01-31 Thread Souvik Dutta
Hi, This is problem from pyqt5. Actually I want to have about 40 labels added into a window when a button is clicked. The text are not the same so the label is not the same. I cannot just add 40 labels before hand and then change its text to something from a qlineedit. Please say me something that

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread R.Wieser
jkn, > I'm happy to consider the risk and choose (eg.) the hash function > accordingly, thanks. No problem, just wanted you to be aware and (thus) able to choose. Regards, Rudy Wieser -- https://mail.python.org/mailman/listinfo/python-list

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread jkn
On Friday, January 31, 2020 at 9:41:32 AM UTC, R.Wieser wrote: > jkn, > > > I think a combination of hashing the URL, > > I hope you're not thinking of saving the hash (into the "done" list) instead > if the URL itself. While hash collisions do not happen often (especially > not in a small li

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread jkn
On Friday, January 31, 2020 at 9:41:32 AM UTC, R.Wieser wrote: > jkn, > > > I think a combination of hashing the URL, > > I hope you're not thinking of saving the hash (into the "done" list) instead > if the URL itself. While hash collisions do not happen often (especially > not in a small li

Python3.8.1 basemap

2020-01-31 Thread J Conrado
Hi, I installed the Python3.8.1 and I run the example of basemap gallery: https://matplotlib.org/basemap/users/examples.html plotgreatcircle.py for Python3.8 plotgreatcircle.py I had: Traceback (most recent call last):   File "plotgreat

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread R.Wieser
jkn, > I think a combination of hashing the URL, I hope you're not thinking of saving the hash (into the "done" list) instead if the URL itself. While hash collisions do not happen often (especially not in a small list), you cannot rule them out. And when that happens that would mean you wo

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread Chris Angelico
On Fri, Jan 31, 2020 at 7:56 PM R.Wieser wrote: > > Dennis, > > > A full client/server RDBM should never be affected by an abort > > of a client program. > > What you describe is on the single query level. What I was thinking of was > having several queries that /should/ work as a single unit, b

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread R.Wieser
DL, >> Nothing that can't be countered by keeping copies of the last X number of >> to-be-dowloaded-URLs files. > > That's a good idea, but how would the automated system 'know' to give-up > on the current file and utilise generation n-1? Unable to open the file or > ??? Well, that would be one r

Re: Suggestions on mechanism or existing code - maintain persistence of file download history

2020-01-31 Thread R.Wieser
Dennis, > A full client/server RDBM should never be affected by an abort > of a client program. What you describe is on the single query level. What I was thinking of was having several queries that /should/ work as a single unit, but could get interrupted (because of the OPs ctrl-c). Yes, C