def _output_new_data(corrected_bpm_data, sdds_file, new_sdds_file_path): """Old sdds_file is used to get the header and meta information for the new_sdds_file.""" new_sdds_file = SDDS_file(new_sdds_file_path) new_sdds_file.file_header = sdds_file.file_header new_sdds_file.bpm_positions = sdds_file.bpm_positions new_sdds_file.bpm_data = corrected_bpm_data new_sdds_file.write_out()
def _output_new_data(corrected_bpm_data, sdds_file, new_sdds_file_path): """Writes the corrected_bpm_data to new_sdds_file_path. Old sdds_file is used to get the header and meta information for the new_sdds_file. Note that sdds_file is an SDDS_file class instance. """ new_sdds_file = SDDS_file(new_sdds_file_path) new_sdds_file.file_header = sdds_file.file_header new_sdds_file.bpm_positions = sdds_file.bpm_positions new_sdds_file.bpm_data = corrected_bpm_data new_sdds_file.write_out()
def _read_in_sdds_file(sdds_file_path): sdds_file = SDDS_file(sdds_file_path) sdds_file.read_in() return sdds_file