Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Re: Writing huge Sets() to disk

Reply
Thread Tools

Re: Writing huge Sets() to disk

 
 
Tim Peters
Guest
Posts: n/a
 
      01-14-2005
[Martin MOKREJ┼*]
> This comm(1) approach doesn't work for me. It somehow fails to
> detect common entries when the offset is too big.
>
> file 1:
>
> A
> F
> G
> I
> K
> M
> N
> R
> V
> AA
> AI
> FG
> FR
> GF
> GI
> GR
> IG
> IK
> IN
> IV
> KI
> MA
> NG
> RA
> RI
> VF
> AIK
> FGR
> FRA
> GFG
> GIN
> GRI
> IGI
> IGR
> IKI
> ING
> IVF
> KIG
> MAI
> NGF
> RAA
> RIG
>
> file 2:
>
> W
> W
> W
> W
> W
> W
> W
> W
> W
> W
> AA
> AI
> FG
> FR
> GF
> GI
> GR
> IG
> IK
> IN
> IV
> KI
> MA
> NG
> RA
> RI
> VF
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA
> AAAAA


I'll repeat:

>> As I mentioned before, if you store keys in sorted text files ...


Those files aren't in sorted order, so of course `comm` can't do
anything useful with them. Do `man sort`; sorting is not optional
here.
 
Reply With Quote
 
 
 
 
=?UTF-8?B?TWFydGluIE1PS1JFSsWg?=
Guest
Posts: n/a
 
      01-14-2005
Tim Peters wrote:
> [Martin MOKREJ┼*]
>
>>This comm(1) approach doesn't work for me. It somehow fails to
>>detect common entries when the offset is too big.


[...]
> I'll repeat:
>
>
>>>As I mentioned before, if you store keys in sorted text files ...

>
>
> Those files aren't in sorted order, so of course `comm` can't do
> anything useful with them. Do `man sort`; sorting is not optional
> here.


I did read the manpage, but somehow it seems I did not execute sort(1)
from within my python code, so it was unsorted and did did not realize
it yet. Thanks!
m.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Memory error due to the huge/huge input file size tejsupra@gmail.com Python 3 11-20-2008 07:21 PM
Re: Writing huge Sets() to disk =?ISO-8859-2?Q?Martin_MOKREJ=A9?= Python 5 01-17-2005 01:25 PM
Writing huge Sets() to disk =?ISO-8859-2?Q?Martin_MOKREJ=A9?= Python 7 01-11-2005 08:42 AM
Re: Writing huge Sets() to disk =?ISO-8859-15?Q?Martin_MOKREJ=A6?= Python 4 01-11-2005 01:13 AM
Re: Writing huge Sets() to disk Tim Peters Python 3 01-11-2005 12:11 AM



Advertisments