Skip Menu |

This queue is for tickets about the PDL_IO_HDF CPAN distribution.

Report information
The Basics
Id: 53815
Status: resolved
Priority: 0/
Queue: PDL_IO_HDF

People
Owner: Nobody in particular
Requestors: fabrice.ducos [...] univ-lille1.fr
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: issue with PDL::IO::HDF::SD
Date: Tue, 19 Jan 2010 12:09:47 +0100
To: bug-PDL_IO_HDF [...] rt.cpan.org
From: Fabrice Ducos <fabrice.ducos [...] univ-lille1.fr>
Hello, first of all thanks for all this work on the PDL package, what you do is really great. I work in a french University on atmospheric research and i'm developing a prototype to read and process satellite data stored in HDF4. I intended to use the PDL::IO::HDF package from CPAN to do this but somehow something is going wrong : i use some parts of the package with success, letting me think that it was installed correctly, but invariably it fails on the call to a specific routine : Here is a sample of code that fails : ######################################################################" #!/usr/bin/env perl use PDL; # version 2.4.3 (got from Synaptic), then 2.4.6 (from CPAN) use PDL::IO::HDF::SD; my $hdf_file = "some_file.hdf"; my $dataset = 'some_existing_dataset'; my $hdf = PDL::IO::HDF::SD->new($hdf_file); my @datasets = sort $hdf->SDgetvariablename(); # this passes my @attrNames = sort $hdf->getattributenames($dataset); # this fails ######################################################################" Here is what i get on my system (Linux loapc-info3 2.6.24-25-generic #1 SMP Tue Oct 20 07:31:10 UTC 2009 i686 GNU/Linux, Ubuntu Hardy Heron) : Can't locate auto/PDL/IO/HDF/SD/getattribut.al in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.8.8 /usr/local/share/perl/5.8.8 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.8 /usr/share/perl/5.8 /usr/local/lib/site_perl .) at ./getattribute.pl line 11 Whatever i do (i've tried to build it from the Synaptic tool, then directly from the sources with Makefile.PL), the file getattribut.al is nowhere to be found in my PDL arborescence. I'm not sure whether it is a bug, but I wonder why it won't get built on my system. Thank you very much for your assistance. F. Ducos
Subject: Re: [rt.cpan.org #53815] issue with PDL::IO::HDF::SD
Date: Thu, 21 Jan 2010 17:40:53 +0100
To: bug-PDL_IO_HDF [...] rt.cpan.org
From: Olivier Archer <olivier.archer [...] ifremer.fr>
2010/1/19 Fabrice Ducos via RT <bug-PDL_IO_HDF@rt.cpan.org> Show quoted text
> Tue Jan 19 06:10:28 2010: Request 53815 was acted upon. > Transaction: Ticket created by ducos > Queue: PDL_IO_HDF > Subject: issue with PDL::IO::HDF::SD > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: fabrice.ducos@univ-lille1.fr > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=53815 > > > > Hello, > > first of all thanks for all this work on the PDL package, what you do is > really great. > > I work in a french University on atmospheric research and i'm developing > a prototype to read and process satellite data stored in HDF4. I > intended to use the PDL::IO::HDF package from CPAN to do this but > somehow something is going wrong : i use some parts of the package with > success, letting me think that it was installed correctly, but > invariably it fails on the call to a specific routine : > > Here is a sample of code that fails : > > ######################################################################" > #!/usr/bin/env perl > > use PDL; # version 2.4.3 (got from Synaptic), then 2.4.6 (from CPAN) > use PDL::IO::HDF::SD; > > my $hdf_file = "some_file.hdf"; > my $dataset = 'some_existing_dataset'; > > my $hdf = PDL::IO::HDF::SD->new($hdf_file); > my @datasets = sort $hdf->SDgetvariablename(); # this passes > my @attrNames = sort $hdf->getattributenames($dataset); # this fails > > ######################################################################" > > Here is what i get on my system (Linux loapc-info3 2.6.24-25-generic #1 > SMP Tue Oct 20 07:31:10 UTC 2009 i686 GNU/Linux, Ubuntu Hardy Heron) : > > Can't locate auto/PDL/IO/HDF/SD/getattribut.al in @INC (@INC > contains: /etc/perl /usr/local/lib/perl/5.8.8 /usr/local/share/perl/5.8.8 > /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.8 /usr/share/perl/5.8 > /usr/local/lib/site_perl .) at ./getattribute.pl line 11 > > Whatever i do (i've tried to build it from the Synaptic tool, then > directly from the sources with Makefile.PL), the file getattribut.al is > nowhere to be found in my PDL arborescence. I'm not sure whether it is a > bug, but I wonder why it won't get built on my system. > > Thank you very much for your assistance. > > F. Ducos > > > >
Hi Fabrice, It seem's that there is a bug in IO/HDF/SD.pd, in sub SDgetattributname SDgetattributname is a wrapper for SDgetattributnames (note the 's') but the wrapper call itself, ie: return $self->SDgetattributename( @_ ); can you try to change it for calling return $self->SDgetattributenames( @_ ); (note the 's') here the diff: diff -ru PDL-2.4.6/IO/HDF/SD/SD.pd PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd --- PDL-2.4.6/IO/HDF/SD/SD.pd 2009-10-17 23:37:41.000000000 +0200 +++ PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd 2010-01-21 10:36:06.000000000 +0100 @@ -702,7 +702,7 @@ sub SDgetattributname { my $self = shift; - return $self->SDgetattributename( @_ ); + return $self->SDgetattributenames( @_ ); } # End of SDgetattributname()... if it (hopfully) work's, we will need someone to commit the change in the main tree, as i haven't play with PDL since 2002. -- Olivier
Subject: Re: [rt.cpan.org #53815] issue with PDL::IO::HDF::SD
Date: Fri, 22 Jan 2010 10:46:11 +0100
To: bug-PDL_IO_HDF [...] rt.cpan.org
From: Fabrice Ducos <fabrice.ducos [...] univ-lille1.fr>
Hi Olivier, thank you very much for your quick reply. I've done the change you suggest in the .pd file, and rebuilt the package, checked that the change was propagated to the .pm file, but it still fails on the same call, with the same error message (the .al file is still not found). Unfortunately i'm not used yet to autoloading in perl, and the reason of this error remains quite mysterious for me. Sorry for annoying you with a subject you've not worked on for years ! Fabrice Show quoted text
> >
> Hi Fabrice, > It seem's that there is a bug in IO/HDF/SD.pd, in sub SDgetattributname > SDgetattributname is a wrapper for SDgetattributnames (note the 's') but the > wrapper call itself, ie: > return $self->SDgetattributename( @_ ); > > can you try to change it for calling > return $self->SDgetattributenames( @_ ); (note the 's') > > here the diff: > diff -ru PDL-2.4.6/IO/HDF/SD/SD.pd PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd > --- PDL-2.4.6/IO/HDF/SD/SD.pd 2009-10-17 23:37:41.000000000 +0200 > +++ PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd 2010-01-21 10:36:06.000000000 +0100 > @@ -702,7 +702,7 @@ > sub SDgetattributname > { > my $self = shift; > - return $self->SDgetattributename( @_ ); > + return $self->SDgetattributenames( @_ ); > } # End of SDgetattributname()... > > > if it (hopfully) work's, we will need someone to commit the change in the > main tree, as i haven't play with PDL since 2002. >
RT-Send-CC: olivier.archer [...] ifremer.fr
Hi Fabrice/Oliver- I was reviewing PDL reports at rt.cpan.org and wondered what ever came of your problem. Unfortunately, I do not know the HDF to be able to assist. As our bugs are handled via the PDL sourceforge.net project page, I'm marking this ticket as stalled pending further response and will duplicate it on sourceforge for our development reference. Regards, Chris On Fri Jan 22 04:46:39 2010, ducos wrote: Show quoted text
> Hi Olivier, > > thank you very much for your quick reply. > I've done the change you suggest in the .pd file, and rebuilt the > package, checked that the change was propagated to the .pm file, but > it > still fails on the same call, with the same error message (the .al > file > is still not found). Unfortunately i'm not used yet to autoloading in > perl, and the reason of this error remains quite mysterious for me. > > Sorry for annoying you with a subject you've not worked on for years ! > > Fabrice >
> > >
> > Hi Fabrice, > > It seem's that there is a bug in IO/HDF/SD.pd, in sub
> SDgetattributname
> > SDgetattributname is a wrapper for SDgetattributnames (note the 's')
> but the
> > wrapper call itself, ie: > > return $self->SDgetattributename( @_ ); > > > > can you try to change it for calling > > return $self->SDgetattributenames( @_ ); (note the 's') > > > > here the diff: > > diff -ru PDL-2.4.6/IO/HDF/SD/SD.pd PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd > > --- PDL-2.4.6/IO/HDF/SD/SD.pd 2009-10-17 23:37:41.000000000 +0200 > > +++ PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd 2010-01-21
> 10:36:06.000000000 +0100
> > @@ -702,7 +702,7 @@ > > sub SDgetattributname > > { > > my $self = shift; > > - return $self->SDgetattributename( @_ ); > > + return $self->SDgetattributenames( @_ ); > > } # End of SDgetattributname()... > > > > > > if it (hopfully) work's, we will need someone to commit the change
> in the
> > main tree, as i haven't play with PDL since 2002. > >
>
Subject: Re: [rt.cpan.org #53815] issue with PDL::IO::HDF::SD
Date: Thu, 01 Apr 2010 12:01:48 +0200
To: bug-PDL_IO_HDF [...] rt.cpan.org
From: Fabrice Ducos <fabrice.ducos [...] univ-lille1.fr>
Hello Chris, Sorry not to have given news earlier. Actually the problem came from two bugs : * one from my side, because of my own forgetfulness : I had mistyped a name (was trying to call SDgetattributename instead of SDgetattributname, notice the missing 'e') and not noticed it for a while. Curiously the error message was not complaining about it, but about a missing getattribut.al file and I suspected there was something broken in my installation. I have few experience in autoloading in perl so the message didn't help me too much. Curiously once I fixed it I still had the same error. It's at the moment that I put my ticket and finally Olivier noticed a bug (a missing 's') in the routine SDgetattributname. Once it is fixed, all works well and I can call without error the method SDgetattributname. Here is a simple code so you can reproduce the problem (you'll need an HDF file for the test). use PDL; use PDL::IO::HDF::SD; my $hdf_file = "/some/path/to/an/existing/hdf/file.hdf"; my $dataset = 'Latitude'; # put any existing dataset here my $hdf = PDL::IO::HDF::SD->new($hdf_file); # Get a list of all datasets: my @dataset_list = $hdf->SDgetvariablename(); # Get a list of the names of all global attributes: #my @globattr_list = $hdf->SDgetattributename(); # faulty version of the test code (notice the 'e') my @globattr_list = $hdf->SDgetattributname(); # fixed version of the test code (no 'e' in the actual name, can be surprising for the user) exit 0; Error message displayed with the faulty version of the test code : Can't locate auto/PDL/IO/HDF/SD/getattribut.al in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.8.8 /usr/local/share/perl/5.8.8 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.8 /usr/share/perl/5.8 /usr/local/lib/site_perl .) at ./test.pl line 15 Error message displayed with the fixed version of the test code and the version 2.4.6 of the package PDL : Can't locate auto/PDL/IO/HDF/SD/getattribut.al in @INC (@INC contains: /etc/perl /usr/local/lib/perl/5.8.8 /usr/local/share/perl/5.8.8 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.8 /usr/share/perl/5.8 /usr/local/lib/site_perl .) at ./test.pl line 15 Error message displayed with Olivier's fix (see below) : No error Best regards Fabrice Le samedi 27 mars 2010 à 19:49 -0400, Chris Marshall via RT a écrit : Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=53815 > > > Hi Fabrice/Oliver- > > I was reviewing PDL reports at rt.cpan.org and wondered what > ever came of your problem. Unfortunately, I do not know the > HDF to be able to assist. As our bugs are handled via > the PDL sourceforge.net project page, I'm marking this > ticket as stalled pending further response and will duplicate > it on sourceforge for our development reference. > > Regards, > Chris > > On Fri Jan 22 04:46:39 2010, ducos wrote:
> > Hi Olivier, > > > > thank you very much for your quick reply. > > I've done the change you suggest in the .pd file, and rebuilt the > > package, checked that the change was propagated to the .pm file, but > > it > > still fails on the same call, with the same error message (the .al > > file > > is still not found). Unfortunately i'm not used yet to autoloading in > > perl, and the reason of this error remains quite mysterious for me. > > > > Sorry for annoying you with a subject you've not worked on for years ! > > > > Fabrice > >
> > > >
> > > Hi Fabrice, > > > It seem's that there is a bug in IO/HDF/SD.pd, in sub
> > SDgetattributname
> > > SDgetattributname is a wrapper for SDgetattributnames (note the 's')
> > but the
> > > wrapper call itself, ie: > > > return $self->SDgetattributename( @_ ); > > > > > > can you try to change it for calling > > > return $self->SDgetattributenames( @_ ); (note the 's') > > > > > > here the diff: > > > diff -ru PDL-2.4.6/IO/HDF/SD/SD.pd PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd > > > --- PDL-2.4.6/IO/HDF/SD/SD.pd 2009-10-17 23:37:41.000000000 +0200 > > > +++ PDL-2.4.6-SzAKLi/IO/HDF/SD/SD.pd 2010-01-21
> > 10:36:06.000000000 +0100
> > > @@ -702,7 +702,7 @@ > > > sub SDgetattributname > > > { > > > my $self = shift; > > > - return $self->SDgetattributename( @_ ); > > > + return $self->SDgetattributenames( @_ ); > > > } # End of SDgetattributname()... > > > > > > > > > if it (hopfully) work's, we will need someone to commit the change
> > in the
> > > main tree, as i haven't play with PDL since 2002. > > >
> >
> > >
RT-Send-CC: olivier.archer [...] ifremer.fr
I've put the fix into the pdl git but am unable to verify without a working test for the problem. It would be great if you could get the latest from git and test the fix. If it works, let me know and I'll mark this as resolved. It would be even better if you could add a test to the t/hdf_sd.t file for the problem. Verify the test fails on the unpatched PDL and passes with the git pdl. Thanks much! Looking forward to hearing back from you. --Chris
RT-Send-CC: olivier.archer [...] ifremer.fr
I've put the fix into the pdl git but am unable to verify without a working test for the problem. It would be great if you could get the latest from git and test the fix. If it works, let me know and I'll mark this as resolved. It would be even better if you could add a test to the t/hdf_sd.t file for the problem. Verify the test fails on the unpatched PDL and passes with the git pdl. Thanks much! Looking forward to hearing back from you. --Chris
Subject: Re: [rt.cpan.org #53815] issue with PDL::IO::HDF::SD
Date: Thu, 01 Apr 2010 19:40:12 +0200
To: bug-PDL_IO_HDF [...] rt.cpan.org
From: Fabrice Ducos <fabrice.ducos [...] univ-lille1.fr>
Hi Chris, I'm ready to do that, but I'm a brand newbie with git for updating CPAN modules. Can you give me the right path to give to the "git clone" command to retrieve a copy of the repository ? (if it's the right way to get it). Not sure I will have the time tomorrow, but I'll try to have a look at it in the current of the next week. Best regards Fabrice Le jeudi 01 avril 2010 à 10:10 -0400, Chris Marshall via RT a écrit : Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=53815 > > > I've put the fix into the pdl git but > am unable to verify without a working > test for the problem. > > It would be great if you could get the > latest from git and test the fix. If > it works, let me know and I'll mark this > as resolved. > > It would be even better if you could > add a test to the t/hdf_sd.t file for > the problem. Verify the test fails on > the unpatched PDL and passes with the > git pdl. > > Thanks much! Looking forward to > hearing back from you. > > --Chris
I've attached some directions on the basic steps to get and test a git version of the PDL development tree. No rush, when you can confirm that things work ok, let me know so I can close out the problem ticket. Thanks, Chris
Subject: checking-pdl-git.txt
Here are the steps I use to build/test a development version of PDL without an install to mess up any pre-installed versions: 1. Get the latest source tree from the sf.net PDL git with cygwin git on windows, linux will have it as well: clone git://pdl.git.sourceforge.net/gitroot/pdl/pdl pdl-git 2. This will download the pdl git source tree into a directory named pdl-git (you can use another directory name here, if you leave it off, the default will be plain old pdl). Now change to that directory: cd pdl-git 3. Configure the PDL build with perl Makefile.PL 4. Compile the PDL build with make 5. Test the PDL build with make test That should go pretty smoothly since you already have PDL installed and are using it so the dependencies should be there already. Once this has been done once, you can just update to a new latest sources by git pull And for my quick config/build/tests I usually use a single line and collect the output in a log file for review with something in bash like: ( set -x ; perl Makefile.PL ; make ; make test ) 2>&1 | tee ../pdl-git-log.txt
CC: pdl-porters [...] jach.hawaii.edu
Subject: Re: git write access ( [rt.cpan.org #53815] issue with PDL::IO::HDF::SD )
Date: Fri, 2 Apr 2010 10:45:22 +0200
To: chm [...] alum.mit.edu, bug-PDL_IO_HDF [...] rt.cpan.org
From: Olivier Archer <olivier.archer [...] ifremer.fr>
Hi Chris, Fabrice & porters, I've tested the current git version, and it's ok, you can close the bug. I'm back after being a long time (8 years) away from pdl. But as PDL::IO::HDF seem's to be (a little) used, i'm ok to fix some bugs, and to add a t/hdf_sd.t Can you help me having a git write access, or do you prefer that i send diff files on pdl-porters ? Olivier 2010/4/1 Chris Marshall via RT <bug-PDL_IO_HDF@rt.cpan.org>: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=53815 > > > I've put the fix into the pdl git but > am unable to verify without a working > test for the problem. > > It would be great if you could get the > latest from git and test the fix.  If > it works, let me know and I'll mark this > as resolved. > > It would be even better if you could > add a test to the t/hdf_sd.t file for > the problem.  Verify the test fails on > the unpatched PDL and passes with the > git pdl. > > Thanks much!  Looking forward to > hearing back from you. > > --Chris > >
RT-Send-CC: olivier.archer [...] ifremer.fr, pdl-porters [...] jach.hawaii.edu
Hi Olivier, Thanks for verifying the fix, I've marked this bug as resolved. It would probably be simplest to attach the patch file to this ticket or to submit it directly to our PDL sourceforge project patches page at: http://sourceforge.net/tracker/?group_id=612&atid=300612 If you wish to contribute more extensively to PDL development let me know. We can enable write access to the repository then. On the other hand, a nice thing about git is that it is also easy to just push patches. Thanks again for taking the time to reply, Chris On Fri Apr 02 04:47:00 2010, OARCHER wrote: Show quoted text
> Hi Chris, Fabrice & porters, > I've tested the current git version, and it's ok, you can close the
bug. Show quoted text
> > > I'm back after being a long time (8 years) away from pdl. But as > PDL::IO::HDF seem's to be (a little) used, i'm ok to fix some bugs, > and to add a t/hdf_sd.t > > Can you help me having a git write access, or do you prefer that i > send diff files on pdl-porters ? > > > Olivier > > > > > 2010/4/1 Chris Marshall via RT <bug-PDL_IO_HDF@rt.cpan.org>:
> > <URL: https://rt.cpan.org/Ticket/Display.html?id=53815 > > > > > I've put the fix into the pdl git but > > am unable to verify without a working > > test for the problem. > > > > It would be great if you could get the > > latest from git and test the fix.  If > > it works, let me know and I'll mark this > > as resolved. > > > > It would be even better if you could > > add a test to the t/hdf_sd.t file for > > the problem.  Verify the test fails on > > the unpatched PDL and passes with the > > git pdl. > > > > Thanks much!  Looking forward to > > hearing back from you. > > > > --Chris > > > >