comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Flaw found in histogram on Red Hat Linux
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Flaw found in histogram on Red Hat Linux [message #20327] Wed, 14 June 2000 00:00 Go to next message
mitch grunes is currently offline  mitch grunes
Messages: 6
Registered: November 1999
Junior Member
Under some conditions, the histogram function causes IDL
to crash with a corrupt array descriptor. I was unable to
duplicate the error on other platforms with older versions
of IDL and PV-WAVE.

I would be curious to know if anyone could test this on
a version of PV-WAVE for Linux, or on recent versions of
IDL on other platforms.

---------Begin Included Program----------

; Attempt by mitch grunes to make IDL histogram fail
; with a corrupt array descriptor.
; The failure is noted on Red Hat Linux 6.0 or Mandrake
; Linux 7.1 with IDL 5.2 or 5.3.
;=========Subroutine==========
pro test1,a
bot=min(a)
top=max(a)
bin=(top-bot)/4000
hist=histogram(a,min=bot,max=top,bin=bin)
end
;=========Main Program=========
for i=0,1000 do begin
print,i
a=randomu(seed,1540,704)
test1,a
endfor
end

----------End Included Program----------

I was able to get around the error by bumping top up a
little, but that seems unsatisfactory.

(I have noted in the past that histogram returned
incorrect values [total of histogram does not equal
# of elements] when handling arrays on the order
of 100,000,000 elements, as though they maybe used
floating point counters instead of integral.
I think it may have been implemented a bit sloppily
in general.)



Sent via Deja.com http://www.deja.com/
Before you buy.
Re: Flaw found in histogram on Red Hat Linux [message #20418 is a reply to message #20327] Fri, 16 June 2000 00:00 Go to previous message
mitch grunes is currently offline  mitch grunes
Messages: 6
Registered: November 1999
Junior Member
I submitted a software trouble report.

IDL says it is in the Linux version, and was fixed in version 5.4.

Sorry--I should have looked to see if IDL had been updated.


Sent via Deja.com http://www.deja.com/
Before you buy.
Re: Flaw found in histogram on Red Hat Linux [message #20420 is a reply to message #20327] Fri, 16 June 2000 00:00 Go to previous message
Luis Alonso is currently offline  Luis Alonso
Messages: 27
Registered: February 2000
Junior Member
I run the code in a WinNT4.0, IDL5.0 and found no trouble at all

but yes, i found some troubles myself with the Histogram function.

Luis Alonso
Re: Flaw found in histogram on Red Hat Linux [message #20424 is a reply to message #20327] Thu, 15 June 2000 00:00 Go to previous message
Vincent Favre-Nicolin is currently offline  Vincent Favre-Nicolin
Messages: 8
Registered: November 1999
Junior Member
grunes@yahoo.com wrote:

> Under some conditions, the histogram function causes IDL
> to crash with a corrupt array descriptor. I was unable to
> duplicate the error on other platforms with older versions
> of IDL and PV-WAVE.
>
> I would be curious to know if anyone could test this on
> a version of PV-WAVE for Linux, or on recent versions of
> IDL on other platforms.

On IDL 5.3 (demo), it crashes :
IDL> .run test2
% Compiled module: TEST1.
% Compiled module: $MAIN$.
0
1
2
3
4
5
6
7
8
9
10
11
% Array has a corrupted descriptor: HIST.
% Execution halted at: TEST1 11
/home/vincent/idl/perso/test2.pro
% $MAIN$ 16
/home/vincent/idl/perso/test2.pro

--
Vincent Favre-Nicolin
Laboratoire de Cristallographie Phone: +41 (22) 702 63 72
24 quai Ernest-Ansermet
CH-1211 Geneva 4, Switzerland Fax: +41 (22) 702 61 08
Re: Flaw found in histogram on Red Hat Linux [message #20425 is a reply to message #20327] Thu, 15 June 2000 00:00 Go to previous message
R is currently offline  R
Messages: 4
Registered: May 2000
Junior Member
Hi,
this program ran with not a problem on Win NT WS4.0 SP5, with IDL 5.2.1.
(i.e. no "corrupt array descriptor")

Cheers,
bob stockwell
stockwell at co-ra dot com


<grunes@yahoo.com> wrote in message news:8i8im3$8u2$1@nnrp1.deja.com...
> Under some conditions, the histogram function causes IDL
> to crash with a corrupt array descriptor. I was unable to
> duplicate the error on other platforms with older versions
> of IDL and PV-WAVE.
>
> I would be curious to know if anyone could test this on
> a version of PV-WAVE for Linux, or on recent versions of
> IDL on other platforms.
>
> ---------Begin Included Program----------
>
> ; Attempt by mitch grunes to make IDL histogram fail
> ; with a corrupt array descriptor.
> ; The failure is noted on Red Hat Linux 6.0 or Mandrake
> ; Linux 7.1 with IDL 5.2 or 5.3.
> ;=========Subroutine==========
> pro test1,a
> bot=min(a)
> top=max(a)
> bin=(top-bot)/4000
> hist=histogram(a,min=bot,max=top,bin=bin)
> end
> ;=========Main Program=========
> for i=0,1000 do begin
> print,i
> a=randomu(seed,1540,704)
> test1,a
> endfor
> end
>
> ----------End Included Program----------
>
> I was able to get around the error by bumping top up a
> little, but that seems unsatisfactory.
>
> (I have noted in the past that histogram returned
> incorrect values [total of histogram does not equal
> # of elements] when handling arrays on the order
> of 100,000,000 elements, as though they maybe used
> floating point counters instead of integral.
> I think it may have been implemented a bit sloppily
> in general.)
>
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Moving a Line
Next Topic: IDL_FileOpen problem?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 20:02:26 PDT 2025

Total time taken to generate the page: 0.44991 seconds