Re: reading text in pdf, some working sample code

2017-11-21 Thread dieter
Daniel Gross writes: > I am new to python and jumped right into trying to read out (english) text > from PDF files. > > I tried various libraries (including slate) You could give "pdfminer" a try. Note, however, that it may not be possible to extract the text: PDF is a generic format which works

Re: How to Generate dynamic HTML Report using Python

2017-11-21 Thread Chris Angelico
On Wed, Nov 22, 2017 at 4:10 PM, Gregory Ewing wrote: > Michael Torrie wrote: >> >> You also have this header set: >> >>> X-Copyright: (C) Copyright 2017 Stefan Ram. All rights reserved. >>> ... It is forbidden to change >>> URIs of this article into links... > > > What is "changing a URI into a l

Re: "help( pi )"

2017-11-21 Thread Chris Angelico
On Wed, Nov 22, 2017 at 4:47 PM, Gregory Ewing wrote: > Cameron Simpson wrote: >> >> one could change implementations such that applying a docstring to an >> object _removed_ it from the magic-shared-singleton pool, > > > That's not sufficient, though. Consider: > >BUFFER_SIZE = 256 >BUF

Re: "help( pi )"

2017-11-21 Thread Gregory Ewing
Cameron Simpson wrote: one could change implementations such that applying a docstring to an object _removed_ it from the magic-shared-singleton pool, That's not sufficient, though. Consider: BUFFER_SIZE = 256 BUFFER_SIZE.__doc__ = "Size of the buffer" TWO_TO_THE_EIGHT = 256 TWO

Re: How to Generate dynamic HTML Report using Python

2017-11-21 Thread Gregory Ewing
Michael Torrie wrote: You also have this header set: X-Copyright: (C) Copyright 2017 Stefan Ram. All rights reserved. ... It is forbidden to change URIs of this article into links... What is "changing a URI into a link" meant to mean? Does it include automatically displaying something that l

Re: reading text in pdf, some working sample code

2017-11-21 Thread Paul Moore
I haven't tried it, but a quick Google search found PyPDF2 - https://stackoverflow.com/questions/34837707/extracting-text-from-a-pdf-file-using-python You don't give much detail about what you tried and how it failed, so if the above doesn't work for you, I'd suggest providing more detail as to wh

Re: __hash__ and ordered vs. unordered collections

2017-11-21 Thread Josh B.
On Monday, November 20, 2017 at 3:17:49 PM UTC-5, Chris Angelico wrote: > Neither is perfect. You have to take your pick between them. Right on, thanks for weighing in, Chris. Your responses have been very helpful. I wouldn't feel comfortable claiming the authority to make this call alone. But f

Re: Posts by Stefan Ram

2017-11-21 Thread Michael Torrie
On 11/21/2017 07:50 AM, Ethan Furman wrote: > Everyone else, please do not quote Stefan's messages as they may then > end up on the mailing list possibly violating his copyright. The good news is, at least, that quoting his messages with attribution is certainly fair use in all jurisdictions I'm a

Re: How to Generate dynamic HTML Report using Python

2017-11-21 Thread Rick Johnson
On Tuesday, November 21, 2017 at 5:57:42 AM UTC-6, Ned Batchelder wrote: [...] > [...] > I don't understand the motivation for limiting how words > are distributed, but others on this list also do it. For > example, Dennis Lee Bieber's messages are not in the > Python-List archives either. I call

reading text in pdf, some working sample code

2017-11-21 Thread Daniel Gross
Hi, I am new to python and jumped right into trying to read out (english) text from PDF files. I tried various libraries (including slate) out there but am running into diverse problems, such as with encoding or buffer too small errors -- deep inside some decompression code. Essentially, i want

Re: How to Generate dynamic HTML Report using Python

2017-11-21 Thread Christopher Reimer
On Nov 21, 2017, at 5:36 AM, Rustom Mody wrote: > >> On Tuesday, November 21, 2017 at 5:27:42 PM UTC+5:30, Ned Batchelder wrote: >>> On 11/20/17 9:50 AM, Stefan Ram wrote: >>> Ned Batchelder writes: Also, why set headers that prevent the Python-List mailing list from archiving your mes

Posts by Stefan Ram

2017-11-21 Thread Ethan Furman
On 11/20/2017 10:47 AM, Michael Torrie wrote:> On 11/20/2017 07:50 AM, Stefan Ram wrote: >>I am posting to a Usenet newsgroup. I am not aware of any >>"Python-List mailing list". > > As far as I'm concerned, this list is primarily a mailing list, hosted > by Mailman at python.org, and is

Re: General Purpose Pipeline library?

2017-11-21 Thread Jason
On Monday, November 20, 2017 at 10:49:01 AM UTC-5, Jason wrote: > a pipeline can be described as a sequence of functions that are applied to an > input with each subsequent function getting the output of the preceding > function: > > out = f6(f5(f4(f3(f2(f1(in)) > > However this isn't very

Re: How to Generate dynamic HTML Report using Python

2017-11-21 Thread Rustom Mody
On Tuesday, November 21, 2017 at 7:06:18 PM UTC+5:30, Rustom Mody wrote: > On Tuesday, November 21, 2017 at 5:27:42 PM UTC+5:30, Ned Batchelder wrote: > > On 11/20/17 9:50 AM, Stefan Ram wrote: > > > Ned Batchelder writes: > > >> Also, why set headers that prevent the Python-List mailing list from

Re: General Purpose Pipeline library? (Posting On Python-List Prohibited)

2017-11-21 Thread Jason
On Monday, November 20, 2017 at 4:02:31 PM UTC-5, Lawrence D’Oliveiro wrote: > On Tuesday, November 21, 2017 at 4:49:01 AM UTC+13, Jason wrote: > > a pipeline can be described as a sequence of functions that are > > applied to an input with each subsequent function getting the output > > of the pre

Re: How to Generate dynamic HTML Report using Python

2017-11-21 Thread Rustom Mody
On Tuesday, November 21, 2017 at 5:27:42 PM UTC+5:30, Ned Batchelder wrote: > On 11/20/17 9:50 AM, Stefan Ram wrote: > > Ned Batchelder writes: > >> Also, why set headers that prevent the Python-List mailing list from > >> archiving your messages? > >I am posting to a Usenet newsgroup. I am no

Re: How to Generate dynamic HTML Report using Python

2017-11-21 Thread Ned Batchelder
On 11/20/17 9:50 AM, Stefan Ram wrote: Ned Batchelder writes: Also, why set headers that prevent the Python-List mailing list from archiving your messages? I am posting to a Usenet newsgroup. I am not aware of any "Python-List mailing list". I am posting specifically to the Usenet, b

Re: how to compare and check if two binary(h5) files numerically have the same contents

2017-11-21 Thread Cameron Simpson
On 21Nov2017 02:04, Heli wrote: I am trying to compare the contents of two binary files. I use python 3.6 filecomp comparing same name files inside two directories. results_dummy=filecmp.cmpfiles(dir1, dir2, common, shallow=True) The above line works for *.bin file I have in both directories,

how to compare and check if two binary(h5) files numerically have the same contents

2017-11-21 Thread Heli
Dear all, I am trying to compare the contents of two binary files. I use python 3.6 filecomp comparing same name files inside two directories. results_dummy=filecmp.cmpfiles(dir1, dir2, common, shallow=True) The above line works for *.bin file I have in both directories, but it does not work