INNER CODE UNIT · Python

current_precentage

pymzml/pymzML · example_scripts/_playground2.py:45

                current_precentage = 100 * float(pos) / float(number_of_specs)
                print(
                    f"[{current_precentage:0>3.1f}%] Access spectrum {i:<10}".format(),
                    end="\r",
                )
                # spec = reader[i]
                try:
                    spec = reader[i]
                    # 100 / 0
                except Exception as e:
                    fails += 1
                    fout.write(f"{os.path.basename(file)}\t{i}\n")
                    print(f"failed on spec {i}")

                    # pprint.pprint(reader.info["file_object"].file_handler.offset_dict)
                    # pprint.pprint(reader.info["file_object"].file_handler.seek_list)
                    spec = reader[i]
                    exit(1)

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…