LakshmiHarika commited on
Commit
037a319
·
verified ·
1 Parent(s): 1f3db4d

Update pages/Data Collection.py

Browse files
Files changed (1) hide show
  1. pages/Data Collection.py +34 -12
pages/Data Collection.py CHANGED
@@ -345,6 +345,7 @@ elif st.session_state.current_page == "explore_images_video":
345
  # Display the plot
346
  st.pyplot(fig)
347
 
 
348
  st.write("""
349
  <div style="text-align: left; margin-top: 20px;">
350
  <h3 style="color: #5b2c6f;">What are Color Spaces?</h3>
@@ -354,7 +355,12 @@ elif st.session_state.current_page == "explore_images_video":
354
  Since machines cannot "see" images as humans do, they interpret numerical values. Therefore, color spaces
355
  are crucial for converting images into a format that can be processed by a machine.
356
  </p>
 
 
357
 
 
 
 
358
  <h4 style="color: #2a52be;">For Example: How Machine Learning Models Work With Images 🖼️</h4>
359
  <p style="font-size: 16px; color: #333;">
360
  Imagine you're building a machine learning model to classify images of dogs and cats. You provide the model with images,
@@ -362,37 +368,53 @@ elif st.session_state.current_page == "explore_images_video":
362
  color spaces play a vital role. They help convert the color information in the images into numbers that the machine
363
  can process, allowing it to learn from the data and make accurate predictions.
364
  </p>
 
 
365
 
 
 
 
366
  <h4 style="color: #5b2c6f;">Common Color Spaces</h4>
367
  <p style="font-size: 16px; color: #333;">
368
  Below are some common color spaces used in image processing:
369
  </p>
 
 
370
 
 
 
 
371
  <h5 style="color: #333;">1. Black and White</h5>
372
  <p style="font-size: 16px; color: #333;">
373
  This color space represents an image with just two colors—black and white. It is often used to simplify images by
374
  focusing on brightness or contrast, removing the color information.
375
  </p>
 
 
376
 
 
 
 
377
  <h5 style="color: #333;">2. Grayscale</h5>
378
  <p style="font-size: 16px; color: #333;">
379
  Grayscale images use different shades of gray to represent the colors in an image. It has 256 levels, ranging from
380
  black to white, with varying intensities of gray in between. This color space is often used in tasks where color is
381
  not essential.
382
  </p>
383
-
384
- <h5 style="color: #333;">3. Red, Green, Blue (RGB)</h5>
385
- <p style="font-size: 16px; color: #333;">
386
- RGB is one of the most common color spaces used in digital imaging. It represents colors by combining red, green,
387
- and blue light. Each channel has values between 0 and 255, and by mixing these three colors, we can create a wide
388
- range of colors.
389
- </p>
390
- </div>
391
- """, unsafe_allow_html=True)
392
-
393
-
394
-
395
 
 
 
 
 
 
 
 
 
 
 
 
396
 
397
 
398
  # Go Back Button
 
345
  # Display the plot
346
  st.pyplot(fig)
347
 
348
+ # Section: What are Color Spaces?
349
  st.write("""
350
  <div style="text-align: left; margin-top: 20px;">
351
  <h3 style="color: #5b2c6f;">What are Color Spaces?</h3>
 
355
  Since machines cannot "see" images as humans do, they interpret numerical values. Therefore, color spaces
356
  are crucial for converting images into a format that can be processed by a machine.
357
  </p>
358
+ </div>
359
+ """, unsafe_allow_html=True)
360
 
361
+ # Section: Example of How ML Models Work with Images
362
+ st.write("""
363
+ <div style="text-align: left; margin-top: 20px;">
364
  <h4 style="color: #2a52be;">For Example: How Machine Learning Models Work With Images 🖼️</h4>
365
  <p style="font-size: 16px; color: #333;">
366
  Imagine you're building a machine learning model to classify images of dogs and cats. You provide the model with images,
 
368
  color spaces play a vital role. They help convert the color information in the images into numbers that the machine
369
  can process, allowing it to learn from the data and make accurate predictions.
370
  </p>
371
+ </div>
372
+ """, unsafe_allow_html=True)
373
 
374
+ # Section: Common Color Spaces
375
+ st.write("""
376
+ <div style="text-align: left; margin-top: 20px;">
377
  <h4 style="color: #5b2c6f;">Common Color Spaces</h4>
378
  <p style="font-size: 16px; color: #333;">
379
  Below are some common color spaces used in image processing:
380
  </p>
381
+ </div>
382
+ """, unsafe_allow_html=True)
383
 
384
+ # Subsection: Black and White
385
+ st.write("""
386
+ <div style="text-align: left; margin-top: 10px;">
387
  <h5 style="color: #333;">1. Black and White</h5>
388
  <p style="font-size: 16px; color: #333;">
389
  This color space represents an image with just two colors—black and white. It is often used to simplify images by
390
  focusing on brightness or contrast, removing the color information.
391
  </p>
392
+ </div>
393
+ """, unsafe_allow_html=True)
394
 
395
+ # Subsection: Grayscale
396
+ st.write("""
397
+ <div style="text-align: left; margin-top: 10px;">
398
  <h5 style="color: #333;">2. Grayscale</h5>
399
  <p style="font-size: 16px; color: #333;">
400
  Grayscale images use different shades of gray to represent the colors in an image. It has 256 levels, ranging from
401
  black to white, with varying intensities of gray in between. This color space is often used in tasks where color is
402
  not essential.
403
  </p>
404
+ </div>
405
+ """, unsafe_allow_html=True)
 
 
 
 
 
 
 
 
 
 
406
 
407
+ # Subsection: RGB
408
+ st.write("""
409
+ <div style="text-align: left; margin-top: 10px;">
410
+ <h5 style="color: #333;">3. Red, Green, Blue (RGB)</h5>
411
+ <p style="font-size: 16px; color: #333;">
412
+ RGB is one of the most common color spaces used in digital imaging. It represents colors by combining red, green,
413
+ and blue light. Each channel has values between 0 and 255, and by mixing these three colors, we can create a wide
414
+ range of colors.
415
+ </p>
416
+ </div>
417
+ """, unsafe_allow_html=True)
418
 
419
 
420
  # Go Back Button