Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -617,7 +617,7 @@ with gr.Blocks(css="""
|
|
617 |
<li>🏷️ <b>labels</b> array: Binary LoS/NLoS values (1/0)</li>
|
618 |
</ul>
|
619 |
</li>
|
620 |
-
<li><b>🔗 Tip</b>:
|
621 |
<li><b>💼 No Downstream Model</b>: Instead of a complex downstream model, we classify each sample based on its distance to the centroid of training samples from each class (LoS/NLoS).</il>
|
622 |
</ul>
|
623 |
</div>
|
@@ -665,17 +665,19 @@ with gr.Blocks(css="""
|
|
665 |
gr.Markdown("""
|
666 |
<div class="explanation-box">
|
667 |
To create a custom dataset, you'll need to structure your data with 32x32 channel matrices, where the rows correspond to antennas at the base station and the columns represent subcarriers. Here’s how to organize and store the channels and labels in an H5 file format for the demo:
|
668 |
-
```python
|
669 |
-
# How to pack channels and labels in a h5 file format as a custom dataset for the demo:
|
670 |
-
import h5py
|
671 |
-
with h5py.File('dataset.h5', 'w') as hdf:
|
672 |
-
hdf.create_dataset('channels', data=channels)
|
673 |
-
hdf.create_dataset('labels', data=labels)
|
674 |
-
print("Dataset saved!")
|
675 |
-
```
|
676 |
</div>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
677 |
""")
|
678 |
|
|
|
679 |
|
680 |
|
681 |
# Launch the app
|
|
|
617 |
<li>🏷️ <b>labels</b> array: Binary LoS/NLoS values (1/0)</li>
|
618 |
</ul>
|
619 |
</li>
|
620 |
+
<li><b>🔗 Tip</b>: Instructions for organizing your dataset are available at the bottom of the page.</li>
|
621 |
<li><b>💼 No Downstream Model</b>: Instead of a complex downstream model, we classify each sample based on its distance to the centroid of training samples from each class (LoS/NLoS).</il>
|
622 |
</ul>
|
623 |
</div>
|
|
|
665 |
gr.Markdown("""
|
666 |
<div class="explanation-box">
|
667 |
To create a custom dataset, you'll need to structure your data with 32x32 channel matrices, where the rows correspond to antennas at the base station and the columns represent subcarriers. Here’s how to organize and store the channels and labels in an H5 file format for the demo:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
668 |
</div>
|
669 |
+
|
670 |
+
```python
|
671 |
+
# How to pack channels and labels in a h5 file format as a custom dataset for the demo:
|
672 |
+
import h5py
|
673 |
+
with h5py.File('dataset.h5', 'w') as hdf:
|
674 |
+
hdf.create_dataset('channels', data=channels)
|
675 |
+
hdf.create_dataset('labels', data=labels)
|
676 |
+
print("Dataset saved!")
|
677 |
+
```
|
678 |
""")
|
679 |
|
680 |
+
|
681 |
|
682 |
|
683 |
# Launch the app
|