标签:html 使用 col 输出 run odi 注意 coding 解决
有二进制文件中保存了 20 亿个 2 Bytes 的数,需将其读出,每 20000 个数作图,拟合后输出结果。
解决
1 # -*- coding: utf-8 -*- 2 """ 3 @author: kurrrr 4 """ 5 6 import struct 7 8 def main(): 9 data_file = open(‘run0035.bin‘, ‘rb‘) 10 data_temp = data_file.read(2) 11 data_short, = struct.unpack(‘h‘, data_temp) 12 print(data_short) 13 14 if __name__ == ‘__main__‘: 15 main()
标签:html 使用 col 输出 run odi 注意 coding 解决
原文地址:https://www.cnblogs.com/kurrrr/p/13160678.html