Refactored import dependencies.
This commit is contained in:
@ -1,17 +1,13 @@
|
|||||||
|
import os
|
||||||
|
|
||||||
import numpy as np
|
import numpy as np
|
||||||
import pandas as pd
|
import pandas as pd
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
import plotly.express as px
|
|
||||||
import plotly.graph_objects as go
|
|
||||||
from plotly.subplots import make_subplots
|
|
||||||
from igor2.binarywave import load as loadibw
|
from igor2.binarywave import load as loadibw
|
||||||
|
|
||||||
#import h5py
|
import src.g5505_utils as utils
|
||||||
import os
|
|
||||||
import tempfile
|
|
||||||
import shutil
|
|
||||||
import h5py
|
import h5py
|
||||||
import g5505_utils as utils
|
|
||||||
|
|
||||||
ROOT_DIR = os.path.abspath(os.curdir)
|
ROOT_DIR = os.path.abspath(os.curdir)
|
||||||
|
|
||||||
@ -125,7 +121,6 @@ def read_txt_files_as_dict(filename : str ):
|
|||||||
|
|
||||||
print(line_number, len(column_names ))
|
print(line_number, len(column_names ))
|
||||||
break
|
break
|
||||||
|
|
||||||
# Subdivide line into words, and join them by single space.
|
# Subdivide line into words, and join them by single space.
|
||||||
# I asumme this can produce a cleaner line that contains no weird separator characters \t \r or extra spaces and so on.
|
# I asumme this can produce a cleaner line that contains no weird separator characters \t \r or extra spaces and so on.
|
||||||
list_of_substrings = line.split()
|
list_of_substrings = line.split()
|
||||||
|
@ -1,17 +1,20 @@
|
|||||||
import pandas as pd
|
import sys
|
||||||
import h5py
|
|
||||||
import os
|
import os
|
||||||
#import sys
|
root_dir = os.path.abspath(os.curdir)
|
||||||
#from itertools import product
|
sys.path.append(root_dir)
|
||||||
|
|
||||||
|
import pandas as pd
|
||||||
import numpy as np
|
import numpy as np
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#import g5505_file_reader
|
#import g5505_file_reader
|
||||||
import g5505_utils as utils
|
import src.g5505_utils as utils
|
||||||
#import smog_chamber_file_reader
|
import input_files.config_file as config_file
|
||||||
|
import src.hdf5_vis as hdf5_vis
|
||||||
|
|
||||||
import config_file
|
import h5py
|
||||||
|
import yaml
|
||||||
|
|
||||||
|
|
||||||
def read_mtable_as_dataframe(filename):
|
def read_mtable_as_dataframe(filename):
|
||||||
@ -456,8 +459,14 @@ def main():
|
|||||||
select_file_keywords = config_file.select_file_keywords #['20220726','2022.07.26']
|
select_file_keywords = config_file.select_file_keywords #['20220726','2022.07.26']
|
||||||
|
|
||||||
output_filename_path = os.path.join(config_file.outputfile_dir,config_file.output_filename)
|
output_filename_path = os.path.join(config_file.outputfile_dir,config_file.output_filename)
|
||||||
|
if not os.path.exists(output_filename_path):
|
||||||
create_hdf5_file_from_filesystem_path(output_filename_path,inputfile_dir,select_dir_keywords,select_file_keywords)
|
create_hdf5_file_from_filesystem_path(output_filename_path,inputfile_dir,select_dir_keywords,select_file_keywords)
|
||||||
#display_group_hierarchy_on_a_treemap(output_filename_path)
|
|
||||||
|
# hdf5_vis.display_group_hierarchy_on_a_treemap(output_filename_path)
|
||||||
|
output_yml_filename_path = hdf5_vis.take_yml_snapshot_of_hdf5_file(output_filename_path)
|
||||||
|
|
||||||
|
|
||||||
|
return output_filename_path, output_yml_filename_path
|
||||||
|
|
||||||
def main_mtable_h5_from_dataframe():
|
def main_mtable_h5_from_dataframe():
|
||||||
|
|
||||||
@ -503,7 +512,6 @@ def main_mtable_h5_from_dataframe():
|
|||||||
|
|
||||||
print(':)')
|
print(':)')
|
||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
|
|
||||||
main()
|
main()
|
||||||
|
@ -1,9 +1,13 @@
|
|||||||
|
|
||||||
import pandas as pd
|
|
||||||
import numpy as np
|
|
||||||
import matplotlib.pyplot as plt
|
|
||||||
import os
|
import os
|
||||||
import g5505_utils as utils
|
|
||||||
|
import numpy as np
|
||||||
|
import pandas as pd
|
||||||
|
from igor2.binarywave import load as loadibw
|
||||||
|
|
||||||
|
import src.g5505_utils as utils
|
||||||
|
|
||||||
|
|
||||||
|
import h5py
|
||||||
|
|
||||||
#def read_txt_files_as_dict(filename : str ,instrument_folder : str):
|
#def read_txt_files_as_dict(filename : str ,instrument_folder : str):
|
||||||
def read_txt_files_as_dict(filename : str ):
|
def read_txt_files_as_dict(filename : str ):
|
||||||
|
Reference in New Issue
Block a user