A PIV data post-processing method of a WAVE bioreactor based on MATLAB
Patent Information
- Application Number
- CN202610806647.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-05
- Publication Date
- 2026-10-09
AI Technical Summary
然而,PIV技术获取的原始数据通常存在空间采样不一致、坐标系方向偏差以及时间序列数据分布离散等问题,导致不同时间点或不同实验工况下的流场难以进行直接对比与动态可视化分析
1、本发明通过对粒子图像测速(PIV)数据进行统一网格化插值与旋转校正处理,有效解决了不同时间步或不同工况下流场数据空间坐标不一致的问题。通过引入基于有效数据点分布的距离阈值掩码机制,精确保留了真实流场区域,抑制了无效区域的插值噪声,显著提升了流场重构的准确性与可视化质量,为复杂流体运动的动态分析提供了高保真、可比对的可视化基础。
Smart Images

Figure CN122887952A_ABST
Abstract
Description
Technical Field
[0001] This invention is a MATLAB-based method for post-processing PIV data from a WAVE bioreactor, belonging to the field of bioengineering and fluid dynamics measurement technology. Background Technology
[0002] Wave bioreactors (WBRs), widely used in cell culture, vaccine production, and biopharmaceuticals, directly influence cell growth environment, nutrient distribution uniformity, and shear stress through their internal flow field characteristics. Therefore, accurately understanding the internal fluid dynamics is crucial for optimizing reactor mixing efficiency and minimizing mechanical damage to cells.
[0003] Particle image velocimetry (PIV), as a non-contact, full-field flow measurement method, has been gradually applied to the study of flow characteristics inside bioreactors. However, the raw data acquired by PIV technology often suffers from problems such as inconsistent spatial sampling, coordinate system orientation deviation, and discrete distribution of time-series data, making it difficult to directly compare and dynamically visualize the flow field at different time points or under different experimental conditions. Existing data processing methods mostly rely on manual intervention, lack a unified gridding mechanism and effective boundary identification strategy, and are prone to introducing interpolation noise, affecting the accuracy of flow field reconstruction.
[0004] Furthermore, most current PIV data analysis workflows still primarily rely on static single-frame displays, lacking a systematic integration and animated presentation of the dynamic evolution of the flow field. This limits the intuitive understanding and process evaluation of key flow characteristics such as instantaneous vortex structures and velocity gradient changes. Therefore, there is an urgent need for an automated and standardized data processing method capable of coordinate correction, high-quality interpolation, effective region identification, and batch dynamic visualization of PIV flow field data to support the hydrodynamic performance analysis and process optimization of wave bioreactors. Summary of the Invention
[0005] To address the problems in the existing technology, this invention provides a MATLAB-based method for post-processing PIV data from a WAVE bioreactor.
[0006] The technical solution adopted by this invention to solve its technical problem is: a post-processing method for PIV data of a WAVE bioreactor based on MATLAB, comprising the following steps: Step S1: Import multiple frames of PIV data into MATLAB in batches, and call MATLAB to build a unified import function to realize batch standardization preprocessing of multiple frames of PIV data. Step S2: Calculate the global bounding box of all frame PIV data on the spatial plane, construct a unified interpolation grid covering the entire data range based on the preset resolution, and store the divided interpolation network. Step S3: After rotating and correcting each frame of PIV data, interpolate it onto the unified interpolation grid and suppress boundary interpolation noise by generating an effective region mask. Step S4: Based on the interpolated velocity field data, generate a comprehensive flow field map containing velocity vector and velocity magnitude information, and output each frame of the image as an independent image file; Specifically, the steps include the following: Step S41: Process each frame of data: Generate a vector distribution cloud map of the two-dimensional flow field, and adjust the relevant display parameters of the drawn vector.
[0007] Step S42: Process each frame of data: Generate a velocity distribution cloud map of the two-dimensional flow field, and adjust the relevant display parameters of the drawn velocity distribution cloud map.
[0008] Step S43: Overlay the velocity distribution cloud map with the vector distribution cloud map and output each frame as an image file.
[0009] Step S5: Combine all the output image files into an animation in chronological order, adjust the relevant display parameters, and output a dynamic visualization video file.
[0010] Further, step S1 includes: Step S11: Use MATLAB's built-in data import function to import any frame of vec format data file.
[0011] Step S12: Select the data range, exclude the data point numbers and variable names from the selection range, and keep only the four columns of data: particle position coordinates (x, y) and velocity components (u, v).
[0012] Step S13: After setting the correct data selection range, generate the corresponding file and import it using the importfile function. This function will be used to import all frame data thereafter.
[0013] Furthermore, the method for constructing the global bounding box in step S2 includes: traversing the x and y coordinates of all frame data, extracting the minimum and maximum values respectively to form an initial bounding box, and expanding it outward by 10% as a buffer area to ensure the integrity of the flow field boundary during the oscillation process.
[0014] Further, the rotation correction in step S3 includes: Set the rotation angle θ and the rotation center point, and use the rotation matrix to perform spatial transformation on the coordinate points (x,y) of each frame of data. At the same time, rotate the velocity vector (u,v) in direction to eliminate the coordinate system tilt caused by camera installation deviation or reactor attitude change.
[0015] Furthermore, the method for generating the effective region mask in step S3 includes at least one of the convex hull method and the distance threshold method.
[0016] The convex hull method constructs a convex hull polygon for each frame's valid data points, uses the inpolygon function to determine whether a uniform grid point is located inside the convex hull, and generates a boolean mask. The distance threshold method calculates the Euclidean distance from each grid point to the nearest valid data point. If the distance is less than a preset threshold, it is marked as a valid region; otherwise, it is set as invalid. The valid data points are those with a resultant velocity greater than 1e⁻. 7 And the data points are neither NaN nor infinite.
[0017] Furthermore, the method for generating the effective region mask in step S3 includes using a trained lightweight U-Net semantic segmentation model to identify effective and invalid regions; The construction of the lightweight U-Net semantic segmentation model includes: Five sets of PIV data were collected under different swing parameters, and the effective area, gas-liquid interface, bag wall, and bubble noise were manually labeled. 80% of the data is used as the training set and 20% as the validation set. The number of training iterations and the learning rate are set, and the cross-entropy loss function is used for optimization. After the model is trained, it is saved to a set location for subsequent inference.
[0018] Furthermore, the lightweight U-Net semantic segmentation model generates effective region masks by including: For each frame of PIV data after preprocessing, a 3-channel input image is generated, namely the velocity amplitude map, the velocity direction map, and the original PIV grayscale image. The 3-channel input image is fed into the trained lightweight U-Net model, and the model outputs a 4-channel segmentation result. The segmentation result of each pixel is converted into a probability value of 0-1 through the Softmax function. The corresponding mask probability is derived based on the preset segmentation probability; An improved radial basis interpolation algorithm is adopted, which uses the mask probability as a weight to embed into the interpolation formula to calculate the interpolation speed of grid points; Smoothing is performed based on the mask probability of the region.
[0019] Furthermore, the specific steps in step S41 for generating the vector distribution map of the two-dimensional flow field include: Step S411: Rotate the original data by an angle θ (optional step).
[0020] Step S412: Interpolate each frame of data onto the grid.
[0021] Step S413: Store the interpolated data.
[0022] Step S414: Filter all valid data points.
[0023] Step S415: Use the quiver3 function to draw the corresponding velocity direction vector arrow for all valid data points.
[0024] Furthermore, the specific steps for generating the velocity distribution cloud map of the two-dimensional flow field in step S41 include: Step S421: Rotate the original data by an angle θ (optional step).
[0025] Step S422: Use the alphashape function to construct a polygonal triangulation mesh that describes the shape of the data based on the discrete points of the original data.
[0026] Step S423: Use the patch function to fill the previously generated polygonal triangulation to obtain the velocity distribution cloud map of the two-dimensional flow field.
[0027] Use the quiver3 function to draw velocity vector arrows with controllable sampling density; at the same time, use either the pcolor or patch function to generate a velocity magnitude distribution cloud map, and map the colors to the jet spectrum; display the two overlays, and automatically add titles, axis labels and color bars.
[0028] Furthermore, the animation compositing method in step S5 includes: Call the MATLAB VideoWriter function, set the frame rate, output format and save path, write the image generated in step S4 frame by frame according to the file name order to generate an MP4 format animation file, save the generated animation file to the preset folder and automatically preview and play it after completion.
[0029] Furthermore, the PIV data is derived from .vec format files collected during the periodic oscillation of the wave-shaped bioreactor, and is used to analyze the fluid motion state inside the flexible bag, supporting the hydrodynamic optimization of the cell culture process.
[0030] The beneficial effects of this invention are: 1. This invention effectively solves the problem of inconsistent spatial coordinates of flow field data under different time steps or operating conditions by performing unified gridded interpolation and rotation correction on particle image velocimetry (PIV) data. By introducing a distance threshold masking mechanism based on the distribution of effective data points, the true flow field region is accurately preserved, and interpolation noise in invalid regions is suppressed, significantly improving the accuracy and visualization quality of flow field reconstruction. This provides a high-fidelity, comparable visualization foundation for the dynamic analysis of complex fluid motion.
[0031] 2. This invention achieves automated batch processing and dynamic visualization output of PIV flow field data. By constructing a standardized data processing workflow, high-quality vector field images are automatically generated and synthesized into animation sequences, which not only significantly improves data processing efficiency but also intuitively displays the dynamic characteristics of the flow field evolution over time. This method reduces the need for manual intervention and is suitable for long-term monitoring and process optimization of complex flow fields such as wave-type bioreactors, exhibiting good repeatability and engineering application value.
[0032] 3. This invention uses a lightweight U-Net model to intelligently identify the above-mentioned effective and invalid regions, generate a soft mask (continuous probability value), and make the mask boundary more accurate, effectively avoiding missed and false judgments; and use the effectiveness score of the soft mask as a weight, so that the effective flow field points dominate the interpolation and the invalid points do not participate in or participate less in the interpolation, thereby suppressing boundary interpolation noise from the root and ensuring accurate velocity calculation. Attached Figure Description
[0033] Other features, objects, and advantages of the present invention will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings: Figure 1 This is a schematic diagram of the motion mode of the swing bioreactor in the PIV data post-processing method of the WAVE bioreactor based on MATLAB in this invention. Figure 2 This is an example diagram of the PIV data import function in the PIV data post-processing method of WAVE bioreactor based on MATLAB of the present invention; Figure 3 This is a global interpolation grid diagram in a MATLAB-based post-processing method for PIV data of a WAVE bioreactor according to the present invention. Figure 4 This is a schematic diagram of the view rotation parameter setting in a MATLAB-based PIV bioreactor PIV data post-processing method of the present invention. Figure 5 This is the final velocity vector distribution map generated in the PIV data post-processing method of a WAVE bioreactor based on MATLAB according to the present invention. Figure 6This is the final time-varying velocity vector distribution map generated in the PIV data post-processing method of a WAVE bioreactor based on MATLAB according to the present invention. Figure 7 This is a screenshot of an mp4 format animation generated in the PIV data post-processing method of a WAVE bioreactor based on MATLAB according to the present invention. Detailed Implementation
[0034] To make the technical means, creative features, objectives and effects of this invention easier to understand, the invention will be further described below in conjunction with specific embodiments.
[0035] Taking WBR as an example, during its operation, the flexible bag containing cell culture medium oscillates periodically back and forth around a horizontal axis, such as... Figure 1 As shown. To study its internal fluid motion characteristics, particle image velocimetry (PIV) was used to collect flow field data at multiple time points. Each frame of data contains particle position coordinates (x, y) and corresponding velocity components (u, v), and the file format is .vec. The following combines... Figures 1 to 7 The data post-processing flow of the present invention will be described in detail.
[0036] First embodiment: This embodiment provides a post-processing method for PIV data from a WAVE bioreactor based on MATLAB, including the following steps: Step S1: Import multiple frames of PIV data into MATLAB in batches, and call MATLAB to build a unified import function to realize batch standardization preprocessing of multiple frames of PIV data. All .vec format PIV data files collected in the experiment are stored in a designated folder. In the MATLAB environment, the built-in "Import Data" function is used to select any frame of data file for initial parsing. For example... Figure 2 As shown, the correct data column range is set through the graphical interface, excluding non-numerical information such as numbers and titles, retaining only the four valid data columns: x, y, u, and v. Subsequently, the system automatically generates the standardized import function importfile_vec.m, as shown... Figure 3 As shown. This function will be used to read all frame data in batches, ensuring a consistent data parsing format and avoiding human error.
[0037] Step S2: Calculate the global bounding box of all frame PIV data on the spatial plane, and construct a unified interpolation grid covering the entire data range based on the preset resolution; To achieve spatial alignment and comparability analysis of multi-frame data, a unified interpolation grid covering the entire data space needs to be established. The system traverses the original coordinate data of all frames, calculates their minimum bounding box in the plane (i.e., the maximum and minimum values of the global x and y coordinates), and then expands the boundary range outward by 10% to reserve an edge buffer area.
[0038] and These are the X and Y ranges of the generated interpolation grid, respectively. and These are the X and Y ranges of the generated interpolation grid, respectively.
[0039] Subsequently, the expanded bounding box is uniformly divided according to a preset grid resolution (e.g., 0.5 mm) to generate a two-dimensional structured mesh. ,like Figure 4 As shown, this unified grid serves as the benchmark for interpolating all subsequent frame data, ensuring the consistency of spatiotemporal data.
[0040] Step S3: After rotating and correcting each frame of PIV data, interpolate it onto the unified interpolation grid and suppress boundary interpolation noise by generating an effective region mask. Step S3 includes step S31, data rotation correction and interpolation processing, and step S32, effective data region identification and mask generation. Specifically, in step S31, because the installation angle of the PIV camera may be deviated, or the coordinate system may be tilted due to changes in the reactor's oscillation posture, the original data needs to be rotated and corrected. For example... Figure 5 As shown, the user can set the rotation angle θ (e.g., 10°) and the coordinates of the rotation center point. The system transforms the coordinate points (x, y) and velocity vectors (u, v) of each frame of data using a rotation matrix. Specifically, the coordinate points undergo translation-rotation-inverse translation to achieve spatial position correction, while the velocity vectors only undergo directional rotation to preserve their vector characteristics. The corrected data is then mapped onto the unified grid constructed in step 2 using the natural neighborhood interpolation method to generate an interpolated velocity field. .
[0041] In step S32, to suppress interpolation noise in invalid regions, it is necessary to identify and retain the true flow field coverage area. This embodiment provides two mask generation strategies: the convex hull method and the distance threshold method. The convex hull method is used for each frame of valid data points (non-NaN, non-infinite, and with a summation velocity greater than the threshold 1e⁻). 7Construct a convex hull polygon, use the inpolygon function to determine whether a grid point is inside the convex hull, and generate a Boolean mask; The distance thresholding method calculates the distance from each grid point to the nearest valid data point. If the distance is less than a preset threshold (e.g., 1.0), it is marked as a valid region. This method more accurately matches the actual data distribution boundary and avoids excessive region expansion caused by the convex hull method. Finally, a mask is applied to the interpolation result, and the velocity values outside the boundary are set to NaN, thus achieving a clear definition of the flow field boundary.
[0042] The calculation formula used in the distance threshold method is: when This grid point is valid at this time. , These are the coordinates of the grid points. , These are the coordinates of the data points, and This is the defined distance threshold.
[0043] Step S4: Based on the interpolated velocity field data, generate a comprehensive flow field map containing velocity vector and velocity magnitude information, and output each frame of the image as an independent image file; After completing the interpolation and masking processes, the flow field is visualized. For example... Figure 6 As shown, the system uses the quiver3 function to draw a velocity vector map, and avoids vector overlap by controlling the sampling density (e.g., drawing an arrow every two grid points). The color of each arrow is based on the magnitude of the resultant velocity at its location (…). The velocity intensity is visually represented by a jet spectrum. Simultaneously, a velocity distribution cloud map is generated using pcolor or background color filling, and overlaid with the vector map to form a comprehensive flow field diagram containing information on velocity magnitude and direction. Image titles, axis labels, color bars, and other elements are automatically generated to ensure complete and consistent formatting of the output image information.
[0044] Step S5: Combine all the output image files into an animation in chronological order, and output a dynamic visualization video file.
[0045] To visually demonstrate the evolution of the flow field over time, the system reads each frame of image generated in step 5 in file order and encapsulates it into a video file. For example... Figure 7As shown, users can set the animation frame rate (e.g., 4 frames / second), output format (MP4), and save path. The system calls the VideoWriter function to write the image frame by frame, generating an .mp4 format animation file. After the animation is generated, a player is automatically invoked for preview, facilitating immediate verification of the processing results. All intermediate data (such as interpolation grids, masks, and processed velocity fields) can also be saved as .mat files for subsequent quantitative analysis.
[0046] Second embodiment: Unlike embodiment one, the masking method is changed. The convex hull method / distance threshold method has fixed rules and cannot adapt to the gas-liquid interface, wave surface, and bubble interference in the WAVE reactor. It cannot accurately distinguish between useful flow field data and invalid regions with useless noise, resulting in inaccurate boundary identification. This embodiment combines machine learning soft masking with mask-aware interpolation, as follows: Step S01: Construct a lightweight U-Net semantic segmentation model. Its inputs are PIV velocity amplitude map, velocity direction map, and original PIV grayscale image; the outputs are four types of segmentation results: effective flow field, gas-liquid interface, bag wall, and bubble noise. The specific training process is as follows: Five sets of different swing parameters are collected, with a frequency range of 10-20 rpm and an angle range of ±5°-±10°. PIV data under these conditions are selected, totaling 5000 frames. The effective area, gas-liquid interface, bag wall, and bubble noise are manually labeled. 80% of the data is used as the training set and 20% as the validation set. The training iterations are 100 times, with a learning rate of 0.001. The cross-entropy loss function is used for optimization. After the model training is completed, it is saved to a set location for subsequent inference.
[0047] Step S02: Generate a 3-channel input image for each frame of preprocessed PIV data, namely a velocity amplitude map, a velocity direction map, and an original PIV grayscale image. Calculate the amplitude of each velocity point in the velocity amplitude graph. Normalize to 0-255 to generate a grayscale image; Calculate the direction angle arctan2 for each velocity point in the velocity direction diagram. Mapping to 0-255 generates a directional grayscale image; The original particle image captured by PIV is directly read from the original PIV grayscale image and then subjected to grayscale normalization processing. Step S03: Input the 3-channel input image into the trained lightweight U-Net model. The model outputs a 4-channel segmentation result. The segmentation result of each pixel is converted into a probability value of 0-1 through the Softmax function to obtain a soft mask image. This probability value represents the possibility that the position belongs to the effective flow field, gas-liquid interface, bag wall, or bubble noise. Specifically, regarding the threshold for the segmentation probability, the effective region rule is defined as follows: The effective flow field region segmentation probability is ≥0.8, and is marked as... , where w is the mask probability; The segmentation probability range of the gas-liquid interface region is 0.6 ≤ segmentation probability < 0.8, denoted as... 0.7-0.9, this It changes linearly with probability; The segmentation probability range of the transition region is 0.3 ≤ segmentation probability < 0.6, denoted as... 0.3-0.6, this It changes linearly with probability; Invalid regions, such as bag walls and bubbles, have a segmentation probability <0.3 and are marked as invalid. 0.
[0048] Step S04: Combine the soft mask image with the PIV velocity point coordinates. Perform mapping and assign a corresponding mask probability to each velocity point. This yields the set of velocity points with masked weights. .
[0049] Step S05: Using an improved radial basis interpolation algorithm, the mask probability is... As a weighted embedding interpolation formula, the specific calculation process is as follows: Step S051: For each grid point Search for 25 PIV velocity points within its 5×5 neighborhood. Step S052: Calculate the spatial distance from each neighboring velocity point to the grid point. ; Step S053: Calculate spatial distance weights ,in As a smoothing coefficient, this embodiment =2mm; Step S054: Calculate the overall weight That is, the spatial distance weight is multiplied by the mask probability weight; Step S055: Calculate the initial interpolation rate of the grid points. : , ; If =0 indicates that the grid point is in an invalid region, and no interpolation will be performed; it will be marked as blank.
[0050] Step S06: Only the region where w≥0.3, i.e. the effective flow field, gas-liquid interface, and transition zone, is subjected to Gaussian smoothing. The invalid region with smoothing coefficient σ=1mm and effectiveness score=0, i.e. the bag wall and bubbles, is not subjected to any smoothing operation to avoid edge noise diffusion and ensure that the flow field edge is clean and free of false velocity.
[0051] This embodiment uses a lightweight U-Net model to intelligently identify the aforementioned effective and invalid regions, generating a soft mask (continuous probability value). The mask boundary is more accurate, effectively avoiding missed and false judgments. Furthermore, the mask-aware interpolation in this embodiment uses the effectiveness score of the soft mask as a weight, allowing effective flow field points to dominate the interpolation while invalid points do not participate or participate less in the interpolation, thus suppressing boundary interpolation noise at its source and ensuring accurate velocity calculation.
[0052] Although this specification describes embodiments, not every embodiment contains only one independent technical solution. This narrative style is merely for clarity. Those skilled in the art should consider the specification as a whole. The technical solutions in each embodiment can also be appropriately combined to form other embodiments that can be understood by those skilled in the art.
Claims
1. A post-processing method for PIV data from a WAVE bioreactor based on MATLAB, characterized in that: include: S1. Import multiple frames of PIV data into MATLAB in batches, and call MATLAB to build a unified import function to realize batch standardization preprocessing of multiple frames of PIV data. S2. Calculate the global bounding box of all frame PIV data on the spatial plane, and construct a unified interpolation grid covering the entire data range based on the preset resolution; S3. After rotating and correcting each frame of PIV data, interpolate it onto the unified interpolation grid and suppress boundary interpolation noise by generating an effective region mask. S4. Based on the interpolated velocity field data, generate a comprehensive flow field map containing velocity vector and velocity magnitude information, and output each frame of the image as an independent image file; S5. Combine all the output image files into an animation in chronological order, and output a dynamic visualization video file.
2. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 1, characterized in that: The generation method of the unified import function in S1 includes: Use MATLAB's built-in data import function to select any frame of .vec format data file, set the correct data column range, exclude numbers and variable names, and keep only the four columns of data: particle position coordinates (x, y) and velocity components (u, v), and automatically generate an importfile function that can be called in batches.
3. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 1, characterized in that: The global bounding box in S2 is constructed in the following ways: Iterate through the x and y coordinates of all frame data, extract the minimum and maximum values to form the initial bounding box, and expand it outward by 10% as a buffer area.
4. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 1, characterized in that: The rotation correction in S3 includes: Set the rotation angle θ and the rotation center point, and use the rotation matrix to perform spatial transformation on the coordinate points (x,y) of each frame of data, while rotating the velocity vector (u,v) in direction.
5. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 1, characterized in that: The method for generating the effective region mask in S3 includes at least one of the convex hull method and the distance threshold method.
6. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 1, characterized in that: The method for generating the effective region mask in S3 includes using a trained lightweight U-Net semantic segmentation model to identify effective and invalid regions. The construction of the lightweight U-Net semantic segmentation model includes: Five sets of PIV data were collected under different swing parameters, and the effective area, gas-liquid interface, bag wall, and bubble noise were manually labeled. 80% of the data is used as the training set and 20% as the validation set. The number of training iterations and the learning rate are set, and the cross-entropy loss function is used for optimization. After the model is trained, it is saved to a set location for subsequent inference.
7. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 6, characterized in that: The lightweight U-Net semantic segmentation model generates effective region masks including: For each frame of PIV data after preprocessing, a 3-channel input image is generated, namely the velocity amplitude map, the velocity direction map, and the original PIV grayscale image. The 3-channel input image is fed into the trained lightweight U-Net model, and the model outputs a 4-channel segmentation result. The segmentation result of each pixel is converted into a probability value of 0-1 through the Softmax function. The corresponding mask probability is derived based on the preset segmentation probability; An improved radial basis interpolation algorithm is adopted, which uses the mask probability as a weight to embed into the interpolation formula to calculate the interpolation speed of grid points; Smoothing is performed based on the mask probability of the region.
8. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 1, characterized in that: The methods for generating the integrated flow field diagram in S4 include: Use the quiver3 function to draw velocity vector arrows, and use either the pcolor or patch function to generate a velocity magnitude distribution cloud map, color-mapped to a jet spectrum; display both overlays, and automatically add titles, axis labels, and color bars.
9. The PIV data post-processing method for WAVE bioreactors based on MATLAB according to claim 1, characterized in that: The animation compositing methods in S4 include: The MATLAB VideoWriter function is called to set the frame rate, output format, and save path. The images generated by S4 are written frame by frame in filename order to generate an MP4 animation file, and the preview is played automatically after completion.
10. The PIV data post-processing method for a MATLAB-based WAVE bioreactor according to any one of claims 1-9, characterized in that: The PIV data is obtained from .vec format files collected during the periodic oscillation of the wave-shaped bioreactor.