[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
AW: textscan
From: |
Graf, Alexander |
Subject: |
AW: textscan |
Date: |
Sun, 29 Apr 2012 18:56:34 +0000 |
Dear Philip, der Ben,
I´m not sure I understand every detail of your discussion, but I can assure you
that you do not need to go into trouble thinking how you can attribute this to
me - it was a very small thing after all and it was a pleasure and very helpful
for me to see your quick reaction and further explanations.
BTW, I had another small problem meanwhile but it might be something very
particular to my input dataset, and thus not relevant for most applications.
Also it seems to happen within strread and I didn´t bother to find out how,
maybe it´s a wanted property of strread: It seems that the output arrays of the
different columns can sometimes have different row numbers (at least by 1, this
happened with my data, maybe because of readin problems with the last row). If
collectoutput is active now, I get an error because I try to concatenate
differently long arrays. I could easily fix this, sufficiently well for my own
application, and the fix is quite ugly so probably nothing to include in
afurther patch. When written in 1 previously empty line to avoid any line
number shifts, it looks like this
Line 279 for ir=1:numel(C);siz(ir)=size(C{ir},1);end;msiz=max(siz');for
ir=1:numel(C);if siz(ir)<msiz;C{ir}=[C{ir}; 0];end;end;%%
________________________________________
Von: Ben Abbott address@hidden
Gesendet: Samstag, 28. April 2012 17:07
An: Philip Nienhuis
Cc: Oactve-maintainers; Graf, Alexander
Betreff: Re: textscan
On Apr 28, 2012, at 10:59 AM, Philip Nienhuis wrote:
> Ben Abbott wrote:
>> On Apr 27, 2012, at 12:31 PM, Philip Nienhuis wrote:
>>
>>> Philip Nienhuis wrote:
>>>> <follow-up cc'd to octave-maintainers ML>
>>>>
>>>> Graf, Alexander wrote:
>>>> <snip>
>>>>> you recently posted a patch to make textscan faster.
>>> <snip>
>>>>> However, I think that in line 168 (of the readily patched
>>>>> file<http://savannah.gnu.org/patch/download.php?file_id=25423>)
>>>>>
>>>>> fskipl (fid, varargin{headerlines + 1});
>>>>>
>>>>> varargin should be replaced by args. At least that was necessary
>>>>> to run it with my script, where some parameters unknown to
>>>>> octave-textscan might have caused empty entries in varargin that
>>>>> are cleared out in args.
>>>>
>>>> Hmmm, I think you are right. Good catch!
>>>> As my patch has already been pushed, I'll (try to) prepare a changeset
>>>> this weekend.
>>>
>>> Changeset attached.
>>>
>>> I also adapted a copyright string in strread.m (was a bit overdue)
>>>
>>> Could one of the core devs please check if it is OK and then push it,
>>> please?
>>>
>>> Thanks,
>>>
>>> Philip
>>> <textscan_strread.patch>
>>
>> Minor detail, but is the summary correct ?
>>
>> "Correct assignment to wrong variable f headerlines processing"
>>
>> Should the "f" be "for" ?
>
> Yes, Ben.
> I'd rather also attribute it to "Alexander Graf <address@hidden>" as he
> proposed this fix but I don't know how to get that together. Plain edit?
> wouldn't that mix up the .hg stuff?
> (my Mercurial knowledge is close to embarrassing)
>
> Could you amend the changeset, please?
>
> TIA, Philip
Yes, a simple text editor can be used to change the "User" attribute.
I've pushed the changeset.
http://hg.savannah.gnu.org/hgweb/octave/rev/e97ec01d4157
Ben
------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------
Forschungszentrum Juelich GmbH
52425 Juelich
Sitz der Gesellschaft: Juelich
Eingetragen im Handelsregister des Amtsgerichts Dueren Nr. HR B 3498
Vorsitzender des Aufsichtsrats: MinDir Dr. Karl Eugen Huthmacher
Geschaeftsfuehrung: Prof. Dr. Achim Bachem (Vorsitzender),
Karsten Beneke (stellv. Vorsitzender), Prof. Dr.-Ing. Harald Bolt,
Prof. Dr. Sebastian M. Schmidt
------------------------------------------------------------------------------------------------
------------------------------------------------------------------------------------------------
Kennen Sie schon unsere app? http://www.fz-juelich.de/app