Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SWarp can't handle images with the same filenames from different folders?
01-04-2013, 23:45
Post: #1
SWarp can't handle images with the same filenames from different folders?
Hi,

I've encountered what I believe is a bug in SWarp. I'll explain with an example:

I have two images, one in each of two folders. We'll call the folders folderA and folderB. If the images are named differently, e.g. folderA/imageA.fits and folderB/imageB.fits, SWarp runs fine.

But if the images are named the same, e.g. folderA/imageA.fits and folderB/imageA.fits, SWarp appears to be unable to cope. It resamples all the images just fine, but (if I understand correctly) when SWarp attempts to write the resampled image it only uses the filename, rather than taking into account the full path.

The first issue with this is that SWarp will overwrite the first resampled image with the second one. The second issue is that when SWarp combines the images it coadds the resampled image the first time, deletes it (I think), then can't find the resampled image when it needs to use it again.

Is there any way around this issue besides renaming my files? Thanks for any help!

-Andrew
Find all posts by this user
Quote this message in a reply
01-10-2013, 23:05
Post: #2
RE: SWarp can't handle images with the same filenames from different folders?
Hi Andrew,

thanks for pointing out this issue! You are right, swarping several files with the same name from different directories will be a problem because (temporary) files containing the resampled data are all saved to the same directory with the .resamp.fits extension by default. I wouldn't say it is a bug though, rather a limitation :-p. But this could be fixed by, e.g., prefixing resampled image files with the original directory name. Let me see what I can do about that.
- Emmanuel.
Visit this user's website Find all posts by this user
Quote this message in a reply
01-11-2013, 07:42
Post: #3
RE: SWarp can't handle images with the same filenames from different folders?
Thanks for the confirmation, Emmanuel, and for the offer to help. If it's a difficult thing to fix in the code don't worry too much about it; I should be able to make my filenames unique before inputting them to SWarp without tons of effort. But I figured I'd ask if there was a simple workaround before going through the trouble of changing filenames.

-Andrew
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)