ndemo commited on
Commit
e37a9b5
·
verified ·
1 Parent(s): 099c794

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +81 -0
README.md CHANGED
@@ -48,3 +48,84 @@ configs:
48
  - split: default
49
  path: snapshots/default-*
50
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48
  - split: default
49
  path: snapshots/default-*
50
  ---
51
+ # Lid-Driven Cavity Flow Dataset
52
+
53
+ ## Dataset Description
54
+
55
+ This dataset contains computational fluid dynamics simulations of the classic lid-driven cavity problem with varying lid velocity parameters.
56
+
57
+ ### Dataset Summary
58
+
59
+ The Lid-Driven Cavity dataset provides numerical simulations of viscous fluid flow in a square cavity with a moving lid. The dataset includes velocity magnitude and pressure fields, representing a fundamental benchmark problem in computational fluid dynamics suitable for validation of numerical methods and machine learning applications.
60
+
61
+ ## Dataset Structure
62
+
63
+ ### Data Instances
64
+
65
+ The dataset consists of three configurations:
66
+
67
+ - **geometry**: Mesh node coordinates
68
+ - **snapshots**: Flow field solutions (velocity magnitude and pressure)
69
+ - **parameters**: Lid velocity values for each simulation
70
+
71
+ ### Data Fields
72
+
73
+ #### Geometry Configuration
74
+ - `node_coordinates_x`: Sequence of x-coordinates of mesh nodes (float64)
75
+ - `node_coordinates_y`: Sequence of y-coordinates of mesh nodes (float64)
76
+
77
+ #### Snapshots Configuration
78
+ - `velocity_magnitude`: Velocity magnitude at each node (float64)
79
+ - `pressure`: Pressure field at each node (float64)
80
+
81
+ #### Parameters Configuration
82
+ - `velocity`: Lid velocity parameter for each simulation (float64)
83
+
84
+ ### Data Splits
85
+
86
+ - `default`: Contains all simulations
87
+
88
+ ## Dataset Creation
89
+
90
+ ### Source Data
91
+
92
+ The dataset was generated using numerical simulations of the incompressible Navier-Stokes equations in a square cavity with a moving top lid. This is a classic benchmark problem used for validating CFD codes.
93
+
94
+ ### Preprocessing
95
+
96
+ Solutions are stored as 1D arrays corresponding to the nodal values. The geometry uses a structured or unstructured mesh representation of the square cavity domain.
97
+
98
+ ## Usage
99
+
100
+ ```python
101
+ from datasets import load_dataset
102
+ import numpy as np
103
+ import matplotlib.pyplot as plt
104
+
105
+ # Load geometry
106
+ ds_geom = load_dataset("SISSAmathLab/lid-cavity", name="geometry")
107
+
108
+ # Load snapshots
109
+ ds_data = load_dataset("SISSAmathLab/lid-cavity", name="snapshots")
110
+
111
+ # Load parameters
112
+ ds_params = load_dataset("SISSAmathLab/lid-cavity", name="parameters")
113
+
114
+ # Visualize velocity magnitude for first simulation
115
+ pts_x = np.asarray(ds_geom['default']['node_coordinates_x']).flatten()
116
+ pts_y = np.asarray(ds_geom['default']['node_coordinates_y']).flatten()
117
+ velocity_mag = ds_data['default']['velocity_magnitude'][0]
118
+
119
+ plt.scatter(pts_x, pts_y, c=velocity_mag, cmap='jet', s=1)
120
+ plt.colorbar(label='Velocity Magnitude')
121
+ plt.title('Lid-Driven Cavity Flow')
122
+ plt.xlabel('x')
123
+ plt.ylabel('y')
124
+ plt.axis('equal')
125
+ plt.show()
126
+ ```
127
+
128
+
129
+ ## Contact
130
+
131
+ For questions or issues, please contact SISSA mathLab.