First, let us express our most sincere hopes that you will never need to read this section... Due to hardware (or even software but this seldom happens) problems data files may become corrupted. Although this is exceptional, it can be a dramatic circumstance. The structure of the data files is fairly complex, and missing information in the index may prevent reading otherwise valid spectra in the data file. If you suspect a file may have been corrupted, first verify it by the following commands :
LAS> FILE IN Dubious_file_name LAS> SET DEFAULT LAS> FIND/ALL LAS> FOR I 1 TO FOUND+1 LAS> GET NEXT LAS> NEXTIf this series of command ends with the message
If not the file is corrupted and you may try to recover it partly. If the FIND command executes correctly, drop (by command DROP) from the index all the scans which cannot be read correctly (these have been lost forever). Then executes the following commands
LAS> FILE OUT Recovered_File_Name NEW LAS> GET FIRST LAS> WRITE LAS> FOR I 1 TO FOUND LAS> GET NEXT LAS> WRITE LAS> NEXT
If the FIND command does not execute correctly, try a LIST IN command to get the scan and version numbers. If it works or if you already have such a list, you may try to get each scan individually by specifying the scan and version numbers, and write them to another output file. In this way you might be able to recover some spectra, but it is not guaranteed.
If nothing like this works and if your file contained vital information you cannot reconstruct in any way, you may consider sending it to the CLASS authors which may be able to do something more. To our knowledge, such a desperate case actually happened only once in the early times of CLASS (at that time named LAS), to the authors who spent about 3 hours to find a way to repair the file, but managed to do it. Do not forget to supply a complete log of the errors (CLASS.LOG and CLASS.MES files).