Batch processing method for static tensile test data of fibers
Through a batch processing of fiber static tensile test data, using Young's modulus linear segment judgment and least squares fitting, the problems of difficult to solve in the prior art data processing time, large errors and curve fluctuations are achieved, and efficient and accurate data processing is achieved.
Patent Information
- Application Number
- CN202411895053.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-21
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2044-12-21
AI Technical Summary
The existing fiber tensile test data processing methods have problems such as high time cost, large error, inability to effectively solve the problem of curve fluctuations, lack of universality and difficulty in verifying data accuracy.
A batch processing method for fiber static tensile test data is proposed. By reading the test data of the tensile machine, the stress and strain data are processed in groups, and a unique Young's modulus linear segment judgment method is used to fit straight lines in combination with the least squares method, and fitting points are marked for visual calibration, reducing data fluctuations and improving data accuracy.
It realizes the rapid and accurate processing of fiber static tensile test data, improves the accuracy and processing efficiency of the data, provides more advantageous data processing methods, and is suitable for fiber material research and other fields.
Smart Images

Figure CN119993335A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of fiber tensile test data processing methods, and in particular to a batch processing method for fiber static tensile test data. Background Art
[0002] At present, during the static tensile test of fiber materials under room temperature conditions, the tensile mechanical properties data will change with the increase of displacement. During the stretching process of different fibers, the rate of change of their Young's modulus is different. In order to improve the accuracy of the data, manual methods are usually used for correction, but it is obvious that this will consume a lot of time when facing large-scale tensile data processing. In addition, during the static tensile process of the fiber, the data curve sometimes fluctuates, which will also interfere with the accuracy of the data, so the tensile data needs to be corrected. Therefore, in the face of batch data processing, the judgment of Young's modulus and the reduction of data fluctuations determine the accuracy of the static tensile mechanical properties data of the fiber.
[0003] In the traditional tensile test process, the tensile machine test recording system will draw a "stress-strain" curve based on the sensor. Then the experimenter needs to import the data into the Origin software, rely on the naked eye to observe the Young's modulus straight line segment on the tensile curve, and determine the end value that conforms to the straight line segment, and then use the values of these straight line segments to fit the straight line to obtain the Young's modulus value. In addition, it is necessary to manually remove the abnormal values of the "stress-strain" curve that produces data fluctuations, and finally use the software to obtain the data of fracture strength, elongation and fracture work.
[0004] Therefore, it is necessary to design a batch processing method for fiber static tensile test data to solve the problems existing in the existing fiber tensile test data processing. The current data processing method mainly uses formulas to correct errors, and often adjusts the tensile machine device to deal with problems such as unclear data starting points. For the problem of curve fluctuation, the existing method cannot effectively solve it; complex mechanical performance indicators such as Young's modulus take a long time to process and have certain errors. They rely on manual judgment of the fitting effect of the stress-strain curve and correct the fitting parameters, but the correction process lacks visualization and is cumbersome. In addition, due to the limitations of the tensile test objects, the existing methods lack versatility and are difficult to use widely. Furthermore, the source of the code is unclear, which makes it impossible to verify the accuracy of the data. For fiber materials with lower stress, there is a lack of convenient and fast data processing methods. Summary of the invention
[0005] In view of this, the present invention proposes a batch processing method for static tensile test data of fibers, aiming to solve the problems existing in the existing fiber tensile test data processing. The current data processing method mainly corrects errors through formulas, and often adjusts the tensile machine device to deal with problems such as unclear data starting points. For the problem of curve fluctuation, the existing method cannot effectively solve it; complex mechanical performance indicators such as Young's modulus have a long processing time and certain errors, and rely on manual judgment of the fitting effect of the stress-strain curve and correction of the fitting parameters, but the correction process lacks visualization and the process is cumbersome. In addition, due to the limitations of the tensile test objects, the method lacks versatility and is difficult to use widely. Furthermore, the source of the code is unclear, which makes it impossible to verify the accuracy of the data. For fiber materials with lower stress, there is a lack of convenient and fast data processing methods.
[0006] In one aspect, the present invention provides a batch processing method for fiber static tensile test data, comprising:
[0007] Read the tensile machine test data, batch select the Excel files of the tensile mechanical properties data of the fiber samples for input and output, group the data, read the data, find the column names of all four columns of the group, and grab the stress and strain data of each group of data;
[0008] Each group of 5 adjacent points is recorded as a group, and the maximum stress difference Vmax and all points greater than Vmax*0.75 are found. The maximum and minimum points are added and divided by 2 to obtain the middle point of the straight line of Young's modulus. Starting from the middle point, the values at both ends away from this point are gradually selected, and a threshold is set for judgment. When the Young's modulus of the selected point is greater than this threshold, starting from this point, the remaining point values away from the middle point are not used to fit the straight line segment;
[0009] The points used for fitting are fitted with the least square method to obtain the Young's modulus, and the points used for fitting are marked in red, and the other points are marked in blue. The dot graph of this set of stress-strain curve data is output, the minimum stress value of the red point is determined, and the data less than the red minimum stress value is deleted. The maximum stress value in the remaining data after processing is determined, and the subsequent data less than the maximum stress is deleted. The processed data is processed into the data origin and output as "calibrated original data";
[0010] Determine the maximum stress value in the "calibrated raw data" and output it as the fracture strength. Output the strain value corresponding to the maximum stress point as the elongation. Calculate the area by integration and output it as the fracture work. Calibrate the fracture strength, elongation, Young's modulus and fracture work in international units to complete the output of a set of data, and process each set of data in a loop.
[0011] The fracture strength, elongation, Young's modulus and fracture work of each set of data in each Excel file are output as Excel files with corresponding file names. The average value and standard deviation of each set of fracture strength, elongation, Young's modulus and fracture work of a single Excel file are calculated, and the average value and standard deviation of all Excel files are output as a total Excel file.
[0012] Furthermore, the reading of the tensile machine test data, batch selection of input and output of the Excel file of the tensile mechanical property data of the fiber samples, and grouping of the data include:
[0013] Select the original data folder, and use the read_excel function in Python's pandas library according to the folder path where the Excel file containing the tensile machine test data is located to traverse all Excel files in the selected folder and read the data into the DataFrame data structure;
[0014] Data screening and grouping: Identify the column information in the file, filter out the data columns related to tensile mechanical properties according to the preset rules, group the data according to the fiber sample number, determine the format of the output tensile mechanical properties data, and create a new DataFrame to store the subsequent calculation results.
[0015] Furthermore, the data is read to find the column names of all four columns of the group, and the stress and strain data of each group of data are captured, including:
[0016] Get the column name information. For each Excel file data that has been read into memory, access the columns attribute of DataFrame to get a list of all column names.
[0017] Filter stress and strain column names, and search the column names of the four columns related to stress and strain data in the column name list according to pre-set rules and user-specified conditions;
[0018] Extract and group the data for storage. Use the stress and strain column names found and the DataFrame indexing method to accurately extract the stress and strain data columns corresponding to each group of data from the original data. Group the extracted data by fiber sample number and store them to form a dictionary data structure. The key is the sample number and the value is a list containing the stress and strain data of the sample.
[0019] Furthermore, each group of 5 adjacent points is recorded as a group, and the maximum stress difference Vmax and all points greater than Vmax*0.75 are found, the maximum and minimum points are added and divided by 2 to obtain the middle point of the straight line portion of the Young's modulus. Starting from the middle point, the values at both ends away from this point are gradually selected, and a threshold is set for judgment. When the Young's modulus of the selected point is greater than the threshold, starting from this point, the remaining point values away from the middle point are not used for fitting the straight line segment, including:
[0020] Calculate stress difference by grouping. For each group of stress data, divide it into groups of 5 adjacent data points. For each group, calculate the stress difference between adjacent points in the group to obtain a group of stress difference data.
[0021] Determine the maximum stress difference Vmax. Use the max function to find the maximum value among all grouped stress difference data, and define it as Vmax.
[0022] Filter the relevant points to determine the middle point, traverse the stress difference data again, find all points corresponding to values greater than Vmax*0.75, and among these relevant points, determine the points with the maximum and minimum stresses, add their stress values and divide by 2 to obtain the reference stress value in the middle of the Young's modulus line, and record the corresponding strain value at the same time, and take the average stress and strain value as the coordinate of the middle reference point;
[0023] The fitting points are selected from the middle point. Starting from the middle reference point, other points are gradually selected towards both ends of the stress-strain curve. For each selected point, its Young's modulus is calculated according to the stress-strain data. A threshold is set. When the Young's modulus of the selected point is greater than the threshold, the selection of points is stopped to determine the range of valid data points for fitting the straight line.
[0024] Furthermore, the Young's modulus is obtained by fitting the points used for fitting with the least square method, and the points used for fitting are marked in red, and the other points are marked in blue, and the dot graph of this set of stress-strain curve data is output, including:
[0025] Straight-line fitting and Young's modulus calculation: extract the stress and strain data of the points selected for fitting the straight line respectively, organize them into a format suitable for least squares fitting, define a linear function form for least squares fitting, use the optimize.curve_fit function in the scipy library, take the prepared data and fitting function as input, perform straight-line fitting, and obtain the parameters of the fitting line. According to the definition of Young's modulus, use the slope obtained by fitting as the value of Young's modulus;
[0026] Data point marking and drawing preparation: Use the matplotlib library to create a graphics object and a coordinate axis object, draw the points used for fitting with red marks on the graph, and draw other points that are not selected for fitting with blue marks. Use the scatter function of the graphics object to pass in the strain and stress data of the fitting points and non-fitting points and the corresponding color parameters, add labels to the coordinate axis to indicate the strain axis label, set the graphic title, add a legend to explain the meaning of the red and blue points, and use the savefig function of the matplotlib library to save the drawn stress-strain curve point graph as an image file.
[0027] Furthermore, the determination of the minimum stress value of the red point and deletion of data less than the minimum stress value of the red point, determination of the maximum stress value in the remaining data after processing, and deletion of subsequent data less than the maximum stress, and data origin processing of the processed data to be output as "calibrated original data" include:
[0028] Determine the minimum stress red point and data deletion. Among the fitting points marked in red, traverse the stress data to find the red point with the minimum stress, then traverse the entire stress-strain data set again and delete all data points with stress values less than the minimum red stress value.
[0029] Determine the maximum stress value and delete subsequent data. Find the maximum stress value in the remaining data after processing, and then delete all subsequent data points with stress values less than the maximum stress value.
[0030] Data origin processing and output: The stress-strain data after two data deletion processes are processed at the origin. The stress-strain value corresponding to the initial unstretched state is set to (0,0), and the coordinates of other data points are adjusted accordingly. The initial stress-strain value is subtracted, and the processed data is stored in a new DataFrame data structure. According to the set output format and path, a file named "calibrated original data" is output.
[0031] Furthermore, the maximum stress value in the “calibrated raw data” is determined and output as the fracture strength, the strain value corresponding to the maximum stress point is output as the elongation, and the area is calculated by the integration method and output as the fracture work, including:
[0032] Determine the breaking strength and elongation, read the "calibrated raw data" file, directly obtain the maximum value from the stress data column as the breaking strength, and find the strain value corresponding to the breaking strength in the data as the elongation. The strain value reflects the elongation of the fiber before breaking;
[0033] To calculate the work of fracture, the integrate.quad function in the scipy library was used to integrate the calibrated stress-strain curve and calculate the area under the stress-strain curve, which represents the energy (work of fracture) absorbed by the fiber during the stretching process. The calculated work of fracture value was recorded as an important parameter for evaluating the tensile properties of the fiber.
[0034] Furthermore, the breaking strength, elongation, Young's modulus and work of fracture are calibrated in international units to complete the output of a set of data, and each set of data is processed cyclically, including:
[0035] Unit calibration: According to the requirements of the International System of Units, the calculated fracture strength, elongation, Young's modulus and fracture work parameters are converted and calibrated. The fracture strength unit is converted to megapascal (MPa), the elongation output unit is converted to 1, the Young's modulus output unit is converted to gigapascal (GPa), and the fracture work unit is converted to megajoule per cubic meter (MJ / m 3 );
[0036] Single set of data output: organize a set of calibrated data according to the set format and output it to the specified result file and data storage structure;
[0037] Each set of data is processed in a loop, and the next set of fiber sample data is processed through the loop structure until all sets of data are processed.
[0038] Furthermore, the method of outputting the fracture strength, elongation, Young's modulus and fracture work of each set of data of each Excel file into an Excel file with a corresponding file name includes:
[0039] Extract and organize data. For each set of data in each processed Excel file, extract its corresponding fracture strength, elongation, Young's modulus and fracture work parameters, and organize them according to the pandas DataFrame structure;
[0040] Output as a separate Excel file: Use the fiber sample number of each set of data or as the file name to output the sorted data as a separate Excel file and store it in the specified output folder.
[0041] Furthermore, the method of calculating the average value and standard deviation of each group of fracture strength, elongation, Young's modulus and fracture work of a single Excel file, and outputting the average values and standard deviations of all Excel files into a total Excel file, includes:
[0042] Calculate the statistical value within a single Excel file. For all the group data in a single Excel file, calculate the mean and standard deviation of the four parameters of fracture strength, elongation, Young's modulus and fracture work respectively. Use the mean function provided by the pandas library to calculate the mean value and the std function to calculate the standard deviation.
[0043] Summarize into a total Excel file, traverse all processed Excel files, collect the mean and standard deviation data of the four parameters calculated in each Excel file, and organize these data into a new DataFrame structure. Each row represents the summary information of an Excel file, and each column is the average value of fracture strength, the average value of elongation, the average value of Young's modulus, the average value of fracture work, the standard deviation of fracture strength, the standard deviation of elongation, the standard deviation of Young's modulus, and the standard deviation of fracture work. Finally, output this summarized DataFrame as a total Excel file and store it in the specified location.
[0044] Compared with the prior art, the beneficial effect of the present invention lies in that a batch processing method of fiber static tensile test data of the present invention, through a unique Young's modulus straight line segment judgment method, combined with precise calculation and screening, accurately determines the position of the straight line segment, providing a reliable basis for subsequent analysis; marking the straight line segment in red can not only intuitively judge the accuracy of the Young's modulus, but also realize the visualization of data accuracy, which is convenient for users to quickly evaluate the data quality; and the use of straight line segments effectively reduces the volatility of the stress-strain curve, further improving the accuracy of the data, which makes the method more accurate and efficient in processing fiber tensile test data as a whole, greatly improving the quality and efficiency of data processing, and providing a more advantageous data processing means for related fields such as fiber material research. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present invention. Moreover, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings:
[0046] Figure 1 This is a flow chart of a batch processing method for fiber static tensile test data according to an embodiment of the present invention;
[0047] Figure 2 An example point diagram of a tensile stress-strain curve according to an embodiment of the present invention;
[0048] Figure 3 An example diagram of modifying the Young's modulus threshold code for an embodiment of the present invention.
[0049] Figure 4This is an example diagram of the software interface of the embodiment of the present invention DETAILED DESCRIPTION
[0050] The exemplary embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although exemplary embodiments of the present invention are shown in the accompanying drawings, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present invention and to be able to fully convey the scope of the present invention to those skilled in the art. It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments can be combined with each other. The present invention will be described in detail below with reference to the accompanying drawings and in conjunction with the implementation regulations.
[0051] Reference Figure 1 As shown, in some embodiments of the present application, a batch processing method for fiber static tensile test data includes:
[0052] Read the tensile machine test data, batch select the Excel files of the tensile mechanical properties data of the fiber samples for input and output, group the data, read the data, find the column names of all four columns of the group, and grab the stress and strain data of each group of data;
[0053] Each group of 5 adjacent points is recorded as a group, and the maximum stress difference Vmax and all points greater than Vmax*0.75 are found. The maximum and minimum points are added and divided by 2 to obtain the middle point of the straight line of Young's modulus. Starting from the middle point, the values at both ends away from this point are gradually selected, and a threshold is set for judgment. When the Young's modulus of the selected point is greater than this threshold, starting from this point, the remaining point values away from the middle point are not used to fit the straight line segment;
[0054] The points used for fitting are fitted with the least square method to obtain the Young's modulus, and the points used for fitting are marked in red, and the other points are marked in blue. The dot graph of this set of stress-strain curve data is output, the minimum stress value of the red point is determined, and the data less than the red minimum stress value is deleted. The maximum stress value in the remaining data after processing is determined, and the subsequent data less than the maximum stress is deleted. The processed data is processed into the data origin and output as "calibrated original data";
[0055] Determine the maximum stress value in the "calibrated raw data" and output it as the fracture strength. Output the strain value corresponding to the maximum stress point as the elongation. Calculate the area by integration and output it as the fracture work. Calibrate the fracture strength, elongation, Young's modulus and fracture work in international units to complete the output of a set of data, and process each set of data in a loop.
[0056] The fracture strength, elongation, Young's modulus and fracture work of each set of data in each Excel file are output as Excel files with corresponding file names. The average value and standard deviation of each set of fracture strength, elongation, Young's modulus and fracture work of a single Excel file are calculated, and the average value and standard deviation of all Excel files are output as a total Excel file.
[0057] Specifically, the above series of steps are implemented by a software for analyzing the static tensile stress-strain curve of composite fibers. It can be understood that the software is easy to operate, can be applied to the processing of tensile stress-strain data of various fibers, and can also understand the accuracy of the data by observing the tensile stress-strain point diagram, which greatly improves the efficiency and accuracy of batch data processing.
[0058] It can be understood that the unique method of judging the straight line segment of Young's modulus provides a reliable basis for subsequent analysis by accurately calculating and screening the straight line segment; marking the straight line segment in red can not only intuitively judge the accuracy of the Young's modulus, but also realize the visualization of data accuracy, which is convenient for users to quickly evaluate the data quality; and the use of straight line segments effectively reduces the volatility of the stress-strain curve, further improving the accuracy of the data. On the whole, this method is more accurate and efficient in processing fiber tensile test data, greatly improving the quality and efficiency of data processing, and providing more advantageous data processing methods for related fields such as fiber material research.
[0059] Specifically, through the corresponding button in the software interface, the user specifies the folder path where the Excel file containing the tensile machine test data is located. The software uses the read_excel function in Python's pandas library to traverse all Excel files in the selected folder, read the data into the DataFrame data structure, identify the column information in the file, and filter out data columns related to tensile mechanical properties, such as stress, strain, etc., according to preset rules or user-defined settings (such as column names containing specific keywords, data types, etc.). Then group the data according to the fiber specimen number or other grouping criteria so that each group of data can be processed separately later. At the same time, determine the format of the output tensile mechanical properties data, such as creating a new DataFrame to store subsequent calculation results, or prepare the corresponding data structure.
[0060] Specifically, for each Excel file data (in the form of DataFrame) that has been read into the memory, the software obtains the list of all column names by accessing the columns property of DataFrame, and searches for the column names of the four columns related to stress and strain data in the column name list according to pre-set rules or user-specified conditions (such as keyword search, data type judgment and other related information), and uses the found stress and strain column names to accurately extract the stress and strain data columns corresponding to each group of data from the original data with the help of DataFrame indexing methods (such as loc or iloc). The extracted data is stored in groups according to the previously determined grouping basis (such as fiber sample number) to form a data structure that is convenient for subsequent processing, such as using a dictionary, with the key being the sample number and the value being a list or DataFrame slice containing the stress and strain data of the sample.
[0061] Reference Figure 2 and Figure 3 As shown, specifically, for each group of stress data, the software divides it into groups of 5 adjacent data points through a loop. For each group, the stress difference between adjacent points in the group is calculated to obtain a set of stress difference data. In the stress difference data of all groups, the maximum value is found using the max function and other methods, which is defined as Vmax. The stress difference data is traversed again to find all points corresponding to values greater than Vmax*0.75. Among these related points, the points with the maximum and minimum stress are determined, and their stress values are added and divided by 2 to obtain a reference stress value roughly in the middle of the straight line part of the Young's modulus. At the same time, the corresponding strain value is recorded, and the stress-strain average value is taken as the coordinate of the intermediate reference point. Starting from the intermediate reference point, other points are gradually selected towards both ends of the stress-strain curve. For each selected point, its Young's modulus (Young's modulus = stress / strain) is calculated according to the stress-strain data. The software sets a threshold (which can be modified based on material properties, experience or by the user through the software interface, such as adjusting the threshold by modifying the values of point1 and point2 in the config file in the example). When the Young's modulus of the selected point is greater than the threshold, the software stops selecting points in that direction, thereby determining the range of valid data points for fitting the straight line.
[0062] It is understandable that the unique calculation and screening method in the processing of fiber static tensile test data can accurately locate the middle point of the straight line part of the Young's modulus. On this basis, the value of the fitting straight line segment is reasonably selected by setting a threshold, which effectively eliminates the interference of the nonlinear part of the curve, making the subsequent calculation of parameters such as Young's modulus more accurate and reliable. At the same time, it helps to improve the scientificity and stability of the entire data processing process, thereby improving the accuracy of the fiber tensile performance analysis, and providing an efficient and high-quality data processing strategy for batch processing of fiber tensile test data.
[0063] Specifically, the software extracts the stress and strain data of the points selected for fitting the straight line, and organizes them into a format suitable for least squares fitting, such as taking the stress data as the dependent variable and the strain data as the independent variable, storing them as two arrays (such as numpy arrays), defining a linear function form (such as y=ax+b, where y is stress, x is strain, a is the slope, and b is the intercept) for least squares fitting, using the optimize.curve_fit function in the scipy library or similar tools, taking the prepared data and the fitting function as input, performing straight line fitting, and obtaining the parameters of the fitting line (slope a and intercept b). According to the definition of Young's modulus, the slope a obtained by fitting is used as the value of Young's modulus.
[0064] Specifically, the matplotlib library is used to create a figure object (Figure) and one or more axis objects (Axes) for drawing the stress-strain curve point graph, and the points used for fitting are drawn with red marks on the graph, and the other points not selected for fitting are drawn with blue marks. The scatter function or similar drawing function of the Axes object is used to input the strain and stress data of the fitting points and non-fitting points and the corresponding color parameters (c = 'r' for red, c = 'b' for blue), add labels to the axis (such as xlabel ('Strain') for the strain axis label, ylabel ('Stress') for the stress axis label), set the graphic title (such as title ('Stress-StrainCurvewithFitting')), add a legend to explain the meaning of the red and blue points, and make the graphics more readable and professional. The savefig function of the matplotlib library is used to save the drawn stress-strain curve point graph as an image file (such as PNG, PDF, etc.), and the save path is set by the software or specified by the user. If you need to view the graphics effect immediately in the script running environment, you can use the show function to display the graphics, but the final software application relies more on saving the graphics file for subsequent viewing and analysis.
[0065] It can be understood that by fitting the straight line through the least squares method to obtain the Young's modulus, accurate modulus values can be obtained based on scientific mathematical principles, providing key data for evaluating the stiffness characteristics of fiber materials; marking the points used for fitting in red, other points in blue, and outputting the stress-strain curve point diagram realizes the visualization of the data processing process, which not only intuitively presents the fitting effect and facilitates the judgment of the rationality and accuracy of the data, but also provides an intuitive basis for the subsequent analysis of data quality and adjustment of processing strategies, effectively enhancing the reliability, interpretability and practicality of the entire fiber static tensile test data batch processing method.
[0066] Specifically, among the fitting points marked in red, the software traverses the stress data and finds the red point with the minimum stress. Then, the entire stress-strain data set is traversed again, and all data points with stress values less than the minimum red stress value are deleted to remove data that may be unstable or abnormally low in stress at the initial stage. The maximum stress value is found in the remaining data after the above processing. Then, all subsequent data points with stress values less than the maximum stress value are deleted to exclude possible abnormal fluctuations or invalid data in the later stage of stretching, to ensure the validity and consistency of the data before the maximum stress point, and to perform origin processing on the stress-strain data after two data deletion processes. Usually, the stress-strain value corresponding to the initial unstretched state is set to (0,0), and the coordinates of other data points are adjusted accordingly, such as by subtracting the initial stress-strain value. The processed data is stored as a new data structure (such as DataFrame), and a file named "calibrated raw data" is output according to the output format and path set by the software as the basic data for the next calculation.
[0067] It is understandable that in the data processing of static tensile test of fibers, this method can effectively remove abnormal fluctuations or invalid data that may exist at the beginning and end of the data. By judging the minimum stress red point and the maximum stress value and deleting the corresponding data, the data can be made purer and in line with the actual tensile law. The data origin processing provides a unified and reasonable benchmark for subsequent calculations. The final output of "calibrated raw data" greatly improves the data quality, laying a solid foundation for accurately analyzing the tensile properties of fibers and calculating key parameters such as breaking strength and elongation, thereby improving the accuracy and reliability of the entire batch processing method.
[0068] Specifically, the software reads the "calibrated raw data" file (Excel file output in the previous step or processed data structure in memory), directly obtains the maximum value from the stress data column as the fracture strength, and searches the strain value corresponding to the maximum stress value in the data as the elongation. The strain value reflects the degree of elongation of the fiber before breaking. The calibrated stress-strain curve is integrated and calculated using a numerical integration method (such as the integrate.quad function in the scipy library or other suitable integration tools). The physical meaning of integration is to calculate the area under the stress-strain curve, which represents the energy absorbed by the fiber during the stretching process, that is, the work of fracture. The calculated work of fracture value is recorded as one of the important parameters for evaluating the tensile properties of the fiber.
[0069] Specifically, according to the requirements of the International System of Units (SI), the software converts and calibrates the parameters such as fracture strength, elongation, Young's modulus and fracture work calculated in step 6. For example, the fracture strength unit may be converted from the original output unit of the tensile machine to megapascal (MPa), the elongation output unit is converted to 1, the Young's modulus output unit is converted to gigapascal (GPa), and the fracture work unit is converted to megajoule per cubic meter (MJ / m 3 ) to ensure that the output parameter units conform to international standards, facilitate data versatility and comparison, and organize a set of calibrated data (including fiber sample number, breaking strength, elongation, Young's modulus, breaking work and other parameters) according to the software setting format and output them to the specified result file or data storage structure.
[0070] Specifically, through the loop structure, the software continues to process the data of the next group of fiber samples until all groups of data have completed the above processing flow, realizing automated processing of the entire batch data and ensuring that each group of data obtains accurate analysis results. For each group of data in each processed Excel file, the software extracts its corresponding parameters such as fracture strength, elongation, Young's modulus and fracture work, and organizes them according to a specific format (such as pandas's DataFrame structure, where each row represents a group of data and each column corresponds to a parameter). The specific identifier of each group of data (such as the fiber sample number or other meaningful name) is used as the file name, and the organized data is output as a separate Excel file and stored in the specified output folder, which is convenient for users to view and analyze the specific performance parameters of each group of data, and facilitates in-depth research or data tracing for individual experiments.
[0071] Specifically, for all the data sets in a single Excel file, the software calculates the mean and standard deviation of the four parameters of breaking strength, elongation, Young's modulus and work of fracture, respectively, using the statistical functions provided by the numpy or pandas library (such as the mean function to calculate the mean, and the std function to calculate the standard deviation). These statistical values are used to describe the overall performance characteristics of the relevant fiber samples in the Excel file. The software traverses all processed Excel files and collects the mean and standard deviation data of the four parameters calculated in each Excel file. These data are organized into a new DataFrame structure, each row represents the summary information of an Excel file, and each column is the mean breaking strength, the mean elongation, the mean Young's modulus, the mean work of fracture, the standard deviation of breaking strength, the standard deviation of elongation, the standard deviation of Young's modulus, the standard deviation of work of fracture, etc. Finally, this summarized DataFrame is output as a total Excel file and stored in a specified location (usually in a folder related to other result data), providing macroscopic statistical analysis results of all processed data, helping users to grasp the overall performance of fiber tensile tests, data dispersion and other information from the overall perspective, and helping to evaluate the quality of fiber materials and the consistency of tensile properties.
[0072] Reference Figure 4 As shown in the figure, the software interface consists of two parts: a folder selection button and a processing button. The data analysis of the fiber sample can be completed without complicated operations.
[0073] Specifically, buttons ①②③④ are folder selection buttons. ① is to select the data folder for fiber samples, and put the Excel file of the data to be processed into the folder. Buttons ②③④ are to select the output file data folder. The results of the output file data are the calibrated original Excel data, the average and standard deviation data of the four parameters calculated in each Excel file and the original four parameter data of each sample, and the stress-strain curve point diagram drawn by each Excel file. Buttons ⑤⑥⑦ are processing buttons. ⑤ is to read and process the original data to generate the calibrated original data. You need to wait for the data to be loaded before clicking the ⑥ button. ⑥ is to generate the average and standard deviation data of the four parameters calculated in each Excel file and the original four parameter data of each sample. You need to wait for the data to be loaded before clicking the ⑦ button. ⑦ is to generate the stress-strain curve point diagram drawn by each Excel file, and each Excel will generate a corresponding folder. This operation method is simple and fast, which can quickly help users learn how to use the software.
[0074] It should be noted that:
[0075] In the description provided herein, a large number of specific details are described. However, it is understood that the embodiments of the present application can be practiced without these specific details. In some instances, well-known structures and technologies are not shown in detail so as not to obscure the understanding of this description.
[0076] Furthermore, those skilled in the art will appreciate that although some embodiments described herein include certain features included in other embodiments but not other features, the combination of features from different embodiments is meant to be within the scope of the present application and to form different embodiments.
[0077] The above is only a preferred specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A batch processing method for fiber static tensile test data, characterized in that: include: Read the tensile machine test data, batch select the Excel files of the tensile mechanical properties data of the fiber samples for input and output, group the data, read the data, find the column names of all four columns of the group, and grab the stress and strain data of each group of data; Each group of 5 adjacent points is recorded as a group, and the maximum stress difference Vmax is found, and all points greater than Vmax*0.75 are found. The maximum and minimum points are added and divided by 2 to obtain the middle point of the straight line of Young's modulus. Starting from the middle point, the values at both ends away from this point are gradually selected, and a threshold is set for judgment. When the Young's modulus of the selected point is greater than this threshold, starting from this point, the remaining point values away from the middle point are not used to fit the straight line segment; The points used for fitting are fitted with the least square method to obtain the Young's modulus, and the points used for fitting are marked in red, and the other points are marked in blue. The dot graph of this set of stress-strain curve data is output, the minimum stress value of the red point is determined, and the data less than the red minimum stress value is deleted. The maximum stress value in the remaining data after processing is determined, and the subsequent data less than the maximum stress is deleted. The processed data is processed into the data origin and output as "calibrated original data"; Determine the maximum stress value in the "calibrated raw data" and output it as the fracture strength. Output the strain value corresponding to the maximum stress point as the elongation. Calculate the area by integration and output it as the fracture work. Calibrate the fracture strength, elongation, Young's modulus and fracture work in international units to complete the output of a set of data, and process each set of data in a loop. The fracture strength, elongation, Young's modulus and fracture work of each set of data in each Excel file are output as Excel files with corresponding file names. The average value and standard deviation of each set of fracture strength, elongation, Young's modulus and fracture work of a single Excel file are calculated, and the average value and standard deviation of all Excel files are output as a total Excel file.
2. The batch processing method for fiber static tensile test data according to claim 1 is characterized in that: The method of reading the tensile machine test data, batch-selecting and inputting Excel files of the tensile mechanical properties data of the fiber samples, and grouping the data includes: Select the original data folder, and use the read_excel function in Python's pandas library according to the folder path where the Excel file containing the tensile machine test data is located to traverse all Excel files in the selected folder and read the data into the DataFrame data structure; Data screening and grouping: Identify the column information in the file, filter out the data columns related to tensile mechanical properties according to the preset rules, group the data according to the fiber sample number, determine the format of the output tensile mechanical properties data, and create a new DataFrame to store the subsequent calculation results.
3. The batch processing method for fiber static tensile test data according to claim 1 is characterized in that: The data is read to find the column names of all four columns of the group, and the stress and strain data of each group of data are captured, including: Get the column name information. For each Excel file data that has been read into memory, access the columns attribute of DataFrame to get a list of all column names. Filter stress and strain column names, and search the column names of the four columns related to stress and strain data in the column name list according to pre-set rules and user-specified conditions; Extract and group the data for storage. Use the stress and strain column names found and the DataFrame indexing method to accurately extract the stress and strain data columns corresponding to each group of data from the original data. Group the extracted data by fiber sample number and store them to form a dictionary data structure. The key is the sample number and the value is a list containing the stress and strain data of the sample.
4. The batch processing method for fiber static tensile test data according to claim 1 is characterized in that: Each group of 5 adjacent points is recorded as a group, and the maximum stress difference Vmax and all points greater than Vmax*0.75 are found. The maximum and minimum points are added and divided by 2 to obtain the middle point of the straight line portion of the Young's modulus. Starting from the middle point, the values at both ends away from this point are gradually selected, and a threshold is set for judgment. When the Young's modulus of the selected point is greater than the threshold, starting from this point, the remaining point values away from the middle point are not used for fitting the straight line segment, including: Calculate stress difference by grouping. For each group of stress data, divide it into groups of 5 adjacent data points. For each group, calculate the stress difference between adjacent points in the group to obtain a group of stress difference data. Determine the maximum stress difference Vmax. Use the max function to find the maximum value among all grouped stress difference data, and define it as Vmax. Filter the relevant points to determine the middle point, traverse the stress difference data again, find all points corresponding to values greater than Vmax*0.75, and among these relevant points, determine the points with the maximum and minimum stresses, add their stress values and divide by 2 to obtain the reference stress value in the middle of the Young's modulus line, and record the corresponding strain value at the same time, and take the average stress and strain value as the coordinate of the middle reference point; The fitting points are selected from the middle point. Starting from the middle reference point, other points are gradually selected towards both ends of the stress-strain curve. For each selected point, its Young's modulus is calculated according to the stress-strain data. A threshold is set. When the Young's modulus of the selected point is greater than the threshold, the selection of points is stopped to determine the range of valid data points for fitting the straight line.
5. The batch processing method for fiber static tensile test data according to claim 1 is characterized in that: The points used for fitting are fitted with the least square method to obtain the Young's modulus. The points used for fitting are marked in red, and the other points are marked in blue. The dot graph of this set of stress-strain curve data is output, including: Straight-line fitting and Young's modulus calculation: First, extract the stress and strain data of the points selected for fitting the straight line, organize them into a format suitable for least squares fitting, define a linear function form for least squares fitting, use the optimize.curve_fit function in the scipy library, take the prepared data and fitting function as input, perform straight-line fitting, and obtain the parameters of the fitting line. According to the definition of Young's modulus, use the slope obtained by fitting as the value of Young's modulus; Data point marking and drawing preparation: Use the matplotlib library to create a graphics object and a coordinate axis object, draw the points used for fitting with red marks on the graph, and draw other points that are not selected for fitting with blue marks. Use the scatter function of the graphics object to pass in the strain and stress data of the fitting points and non-fitting points and the corresponding color parameters, add labels to the coordinate axis to indicate the strain axis label, set the graphic title, add a legend to explain the meaning of the red and blue points, and use the savefig function of the matplotlib library to save the drawn stress-strain curve point graph as a picture file.
6. The batch processing method for fiber static tensile test data according to claim 1 is characterized in that: The above-mentioned steps of determining the minimum stress value of the red point and deleting the data less than the minimum stress value of the red point, determining the maximum stress value in the remaining data after processing, and deleting the subsequent data less than the maximum stress value, processing the processed data to the data origin, and outputting it as "calibrated original data" include: Determine the minimum stress red point and data deletion. Among the fitting points marked in red, traverse the stress data to find the red point with the minimum stress, then traverse the entire stress-strain data set again and delete all data points with stress values less than the minimum red stress value. Determine the maximum stress value and delete subsequent data. Find the maximum stress value in the remaining data after processing, and then delete all subsequent data points with stress values less than the maximum stress value. Data origin processing and output: The stress-strain data after two data deletion processes are processed at the origin. The stress-strain value corresponding to the initial unstretched state is set to (0,0), and the coordinates of other data points are adjusted accordingly. The initial stress-strain value is subtracted, and the processed data is stored as a new DataFrame data structure. According to the set output format and path, a file named "calibrated original data" is output.
7. The batch processing method for fiber static tensile test data according to claim 1 is characterized in that: The maximum stress value in the "calibrated raw data" is determined and output as the fracture strength, the strain value corresponding to the maximum stress point is output as the elongation, and the area is calculated by the integration method and output as the fracture work, including: Determine the breaking strength and elongation, read the "calibrated raw data" file, directly obtain the maximum value from the stress data column as the breaking strength, and find the strain value corresponding to the breaking strength in the data as the elongation. The strain value reflects the elongation of the fiber before breaking; To calculate the work of fracture, the integrate.quad function in the scipy library was used to integrate the calibrated stress-strain curve and calculate the area under the stress-strain curve, which represents the energy (work of fracture) absorbed by the fiber during the stretching process. The calculated work of fracture value was recorded as an important parameter for evaluating the tensile properties of the fiber.
8. The batch processing method for fiber static tensile test data according to claim 1 is characterized in that: The breaking strength, elongation, Young's modulus and work of fracture are calibrated in international units to complete the output of a set of data, and each set of data is processed cyclically, including: Unit calibration: According to the requirements of the International System of Units, the calculated fracture strength, elongation, Young's modulus and fracture work parameters are converted and calibrated. The fracture strength unit is converted from the original output unit of the tensile machine to megapascal (MPa), the elongation unit is converted to 1, the Young's modulus unit is converted to gigapascal (GPa), and the fracture work unit is converted to megajoule per cubic meter (MJ / m 3 ); Single set of data output: organize a set of calibrated data according to the set format and output it to the specified result file and data storage structure; Each set of data is processed in a loop, and the next set of fiber sample data is processed through the loop structure until all sets of data are processed.
9. The batch processing method for fiber static tensile test data according to claim 1, characterized in that: The method of outputting the fracture strength, elongation, Young's modulus and fracture work of each set of data in each Excel file to an Excel file with a corresponding file name includes: Extract and organize data. For each set of data in each processed Excel file, extract its corresponding fracture strength, elongation, Young's modulus and fracture work parameters, and organize them according to the pandas DataFrame structure; Output as a separate Excel file: Use the fiber sample number of each set of data or as the file name to output the sorted data as a separate Excel file and store it in the specified output folder.
10. The batch processing method for fiber static tensile test data according to claim 1, characterized in that: The method of using a single Excel file to calculate the average value and standard deviation of each group of fracture strength, elongation, Young's modulus and fracture work, and outputting the average values and standard deviations of all Excel files into a total Excel file, includes: Calculate the statistical value within a single Excel file. For all the group data in a single Excel file, calculate the mean and standard deviation of the four parameters of fracture strength, elongation, Young's modulus and fracture work respectively. Use the mean function provided by the pandas library to calculate the mean value and the std function to calculate the standard deviation. Summarize into a total Excel file, traverse all processed Excel files, collect the mean and standard deviation data of the four parameters calculated in each Excel file, and organize these data into a new DataFrame structure. Each row represents the summary information of an Excel file, and each column is the average value of fracture strength, the average value of elongation, the average value of Young's modulus, the average value of fracture work, the standard deviation of fracture strength, the standard deviation of elongation, the standard deviation of Young's modulus, and the standard deviation of fracture work. Finally, output this summarized DataFrame as a total Excel file and store it in the specified location.
Citation Information
Patent Citations
An efficient liner fitting method
CN108959762A
Uniaxial tension test data analysis method based on anisotropy
CN112685687A
Automatic processing method and system for stress-strain data in root system tension state
CN117332189A
Method for measuring and determining fracture toughness of structural material in high-temperature environment
WO2016045024A1