[DAMD-12] Change order of spectrograph and arm in data model from e.g. 1r to e.g. r1 Created: 11/Nov/16  Updated: 27/Jul/17  Resolved: 27/Jul/17

Status: Done
Project: Data Model
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Story Priority: Major
Reporter: rhl Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Blocks
blocks PIPE2D-118 Make sure that all file names in the ... Done

 Description   

Currently the data model specifies that we include the spectrograph number and arm in filenames as e.g.

 "pfsArm-%06d-%1d%1s.fits" % (visit, spectrograph, arm)

Unfortunately, some outputs (e.g. calibrated exposures) are written as

 "%1s%1d" % (arm, spectrograph)

so something has to be changed. I'd like to change it from e.g. "1r" to e.g. "r1" as:

  1. consistency is vital!
  2. the chip name can now be used as a variable
  3. it's consistent with the naming we used in SDSS
  4. while this change means that filenames will sort differently, as the main sort key is usually the visit the 12 files associated with a visit will still be together, and we feel that this is acceptable.

We will also need to switch the last two digits in raw file names (e.g. PFSA files); Craig and I agree that this is worth it at this point in the project where he owns all the raw data.

N.b. This is our last opportunity to make this change; once we've started taking data at LAM we are frozen for the rest of the life of the instrument.



 Comments   
Comment by naoyuki.tamura [ 11/Nov/16 ]

I fully understand and agree that the consistency is critical. But perhaps I still don't fully understand the main reason for the swap of the last two digits. Being the same as SDSS is it? Or Craig already created valuable output files from the PFS detectors with them swapped?

Comment by rhl [ 27/Jul/17 ]

Well, shall we do it? (I'm working on camera description files, so now's the time).

Craig: note the comment
> We will also need to switch the last two digits in raw file names (e.g. PFSA files)

Comment by shimono [ 27/Jul/17 ]

I don't against to swap pfsArm definition (or I'd say point 4 seems reasonable), but I don't feel swapping two for PFSA* is a good idea. Two identifiers are in "%1d%1d" not like pfsArm's "%1s%1d", so all 8 digits are in the same character category. For these, it seems for me to be natural with following organization, such as visit -> spectrograph -> arm.

Comment by cloomis [ 27/Jul/17 ]

I vote for leaving the raw camera files as-is (spectrograph-arm), and making all subsequent files arm-spectrograph ("r1").

Besides the DRP ingestion step, the only systems which handle raw files are in the instrument realm, where the hierarchy (instrument-spectrograph-dewar) is significant and makes sense.

All other files are in the realm of DRP, where it can be more convenient to use names like "r1".

Comment by rhl [ 27/Jul/17 ]

OK, I'm going to adopt this:

  • Raw filenames remain PFXYVVVVVVSA.fits (V: Visit S: Spectrograph# A: Arm#
  • All other files are named by as: a: arm name s: spectrograph number

E.g. pfsArm-002026-r1.fits

I will update the data model code to support this convention, but it will take a modification to the "Hirata" simulator to see this change (specifically we'll have to change which version of the data model product it pulls in as a git submodule)

Generated at Sat Feb 10 15:33:19 JST 2024 using Jira 8.3.4#803005-sha1:1f96e09b3c60279a408a2ae47be3c745f571388b.