A check standard report is a summary of one of the devices used in the NIST check standard program. Reports can be either a comparison of a one or two port measurement file that has multiple connect measurements, with the metadata Connector_Type_Measurement and with the historical database or just a summary of a device with respect to time. The metadata normally attached with the device measurement is
keys=["System_Id","System_Letter","Connector_Type_Calibration","Connector_Type_Measurement",
"Measurement_Type","Measurement_Date","Measurement_Time","Program_Used","Program_Revision","Operator",
"Calibration_Name","Calibration_Date","Port_Used","Number_Connects","Number_Repeats","Nbs",
"Number_Frequencies","Start_Frequency",
"Device_Description","Device_Id"]
from pyMez.Code.Analysis.Reports import *
report_1=CheckStandardReport(Device_Id="CTNP14")
# This displays the report in a browser
report_1.show()
# This is the default path
report_1.path
# This saves the report as an html file under a different name
report_1.path=os.path.join(os.getcwd(),"CheckStandard_Files/CheckStandard_Report_CTN202.html")
report_1.save()
By just passing a file path of a measurement with the proper metadata it automatically compares the file with the database values and creates the html report.
measurement_path=os.path.join(os.getcwd(),"CheckStandard_Files/C07208.L6_041304")
report_2=CheckStandardReport(file_path=measurement_path)
# This displays the report in a browser
report_2.show()
# This saves the file
report_2.path=os.path.join(os.getcwd(),"CheckStandard_Files/CheckStandard_Report_C07208.html")
report_2.save()
The constants in the module pyMez.Code.Analysis.Reports define the location of the data base.
TWO_PORT_NR_CHKSTD_CSV=r"C:\Share\Converted_Check_Standard\Two_Port_NR_Check_Standard.csv"
COMBINED_ONE_PORT_CHKSTD_CSV=r"C:\Share\Converted_Check_Standard\Combined_One_Port_Check_Standard.csv"
COMBINED_TWO_PORT_CHKSTD_CSV=r"C:\Share\Converted_Check_Standard\Combined_Two_Port_Check_Standard.csv"
COMBINED_POWER_CHKSTD_CSV=r"C:\Share\Converted_Check_Standard\Combined_Power_Check_Standard.csv"
ONE_PORT_CALREP_CSV=r"C:\Share\Converted_DUT\One_Port_DUT.csv"
TWO_PORT_CALREP_CSV=r"C:\Share\Converted_DUT\Two_Port_DUT.csv"
POWER_3TERM_CALREP_CSV=r"C:\Share\Converted_DUT\Power_3Term_DUT.csv"
POWER_4TERM_CALREP_CSV=r"C:\Share\Converted_DUT\Power_4Term_DUT.csv"