1// Module 1 Comprehensive Handouts - Part 2 (m1-t5 to m1-t10) 2// Career, Math, Statistics, Linear Algebra, Data Types, Data Collection 3 4const module1HandoutsPart2 = { 5 'm1-t5': ` 6 <div class="handout-premium"> 7 <div class="topic-header"> 8 <h1>ð¾ Career Opportunities in AgriTech</h1> 9 <p class="duration">â±ï¸ Duration: 1 hour</p> 10 </div> 11 12 <div class="learning-objectives"> 13 <h2>ð Learning Objectives</h2> 14 <ul> 15 <li>Explore career paths in agricultural technology</li> 16 <li>Understand required skills for AgriTech roles</li> 17 <li>Identify major companies and startups in the field</li> 18 <li>Plan your learning journey for AgriTech careers</li> 19 </ul> 20 </div> 21 22 <div class="farming-analogy"> 23 <h2>ð The Farming Connection</h2> 24 <div class="analogy-box"> 25 <p><strong>AgriTech Careers = Farming the Future</strong></p> 26 <p>Just as farmers cultivate crops, you can cultivate skills that will help you grow a career at the intersection of technology and agriculture. The field is ripe for harvest!</p> 27 </div> 28 </div> 29 30 <div class="core-concepts"> 31 <h2>ð Career Paths</h2> 32 33 <h3>1. Data Scientist (Agriculture)</h3> 34 <ul> 35 <li><strong>Role:</strong> Analyze farm data, build prediction models</li> 36 <li><strong>Skills:</strong> Python, ML, Statistics, Domain knowledge</li> 37 <li><strong>Salary:</strong> â¹8-25 LPA in India</li> 38 </ul> 39 40 <h3>2. Machine Learning Engineer</h3> 41 <ul> 42 <li><strong>Role:</strong> Deploy ML models for agricultural applications</li> 43 <li><strong>Skills:</strong> TensorFlow, PyTorch, Cloud platforms</li> 44 <li><strong>Salary:</strong> â¹10-30 LPA in India</li> 45 </ul> 46 47 <h3>3. Precision Agriculture Specialist</h3> 48 <ul> 49 <li><strong>Role:</strong> Implement precision farming solutions</li> 50 <li><strong>Skills:</strong> GIS, Remote sensing, IoT, Data analysis</li> 51 <li><strong>Salary:</strong> â¹6-15 LPA in India</li> 52 </ul> 53 54 <h3>4. AgriTech Product Manager</h3> 55 <ul> 56 <li><strong>Role:</strong> Bridge technology and farmer needs</li> 57 <li><strong>Skills:</strong> Technical knowledge + Business acumen</li> 58 <li><strong>Salary:</strong> â¹12-35 LPA in India</li> 59 </ul> 60 61 <h3>Top AgriTech Companies in India</h3> 62 <ul> 63 <li>ð± <strong>CropIn</strong> - Farm management platform</li> 64 <li>ð¾ <strong>DeHaat</strong> - Full-stack agri platform</li> 65 <li>ð <strong>Fasal</strong> - IoT-based farm intelligence</li> 66 <li>ð± <strong>Plantix</strong> - AI disease detection</li> 67 <li>ð¿ <strong>Ninjacart</strong> - Supply chain optimization</li> 68 </ul> 69 </div> 70 71 <div class="student-activity"> 72 <h2>ð¯ Hands-On Activity</h2> 73 <div class="activity-box"> 74 <h3>Career Exploration</h3> 75 <ol> 76 <li>Visit LinkedIn and search for "AgriTech Data Scientist India"</li> 77 <li>Find 3 job postings and list their required skills</li> 78 <li>Match your current skills and identify gaps</li> 79 <li>Create a 6-month learning plan to fill those gaps</li> 80 </ol> 81 </div> 82 </div> 83 84 <div class="quiz-section"> 85 <h2>ð Knowledge Check</h2> 86 87 <div class="quiz-question"> 88 <p><strong>Q1:</strong> Which skill is MOST essential for an agricultural data scientist?</p> 89 <ul> 90 <li>A) Graphic design</li> 91 <li>B) Python programming and statistics</li> 92 <li>
92C) Hardware repair</li> 93 <li>D) Video editing</li> 94 </ul> 95 <details> 96 <summary>Show Answer</summary> 97 <p><strong>Answer: B</strong> - Data scientists need programming and statistics skills to analyze data and build models.</p> 98 </details> 99 </div> 100 </div> 101 102 <div class="summary"> 103 <h2>ð Key Takeaways</h2> 104 <ul> 105 <li>AgriTech is a rapidly growing field with diverse career opportunities</li> 106 <li>Python, ML, and domain knowledge are key skills</li> 107 <li>India has many successful AgriTech startups</li> 108 <li>Combining agriculture knowledge with tech skills is highly valuable</li> 109 </ul> 110 </div> 111 </div> 112 `, 113 114 'm1-t6': ` 115 <div class="handout-premium"> 116 <div class="topic-header"> 117 <h1>ð¾ Mathematical Foundations for ML</h1> 118 <p class="duration">â±ï¸ Duration: 3 hours</p> 119 </div> 120 121 <div class="learning-objectives"> 122 <h2>ð Learning Objectives</h2> 123 <ul> 124 <li>Understand why mathematics is essential for ML</li> 125 <li>Review key mathematical concepts used in ML</li> 126 <li>Apply basic math to agricultural data scenarios</li> 127 </ul> 128 </div> 129 130 <div class="farming-analogy"> 131 <h2>ð The Farming Connection</h2> 132 <div class="analogy-box"> 133 <p><strong>Math in Farming = Measuring Your Success</strong></p> 134 <p>Just as you measure field area, calculate seed quantities, and estimate yields - ML uses math to measure patterns, calculate predictions, and estimate outcomes. The units are different, but the thinking is similar!</p> 135 </div> 136 </div> 137 138 <div class="core-concepts"> 139 <h2>ð Core Concepts</h2> 140 141 <h3>1. Why Math Matters for ML</h3> 142 <ul> 143 <li><strong>Data Representation:</strong> Numbers describe everything (temperature, yield, price)</li> 144 <li><strong>Pattern Finding:</strong> Math helps identify relationships in data</li> 145 <li><strong>Optimization:</strong> Finding the "best" solution mathematically</li> 146 </ul> 147 148 <h3>2. Key Mathematical Areas</h3> 149 <table> 150 <tr> 151 <th>Area</th> 152 <th>ML Application</th> 153 <th>Farm Example</th> 154 </tr> 155 <tr> 156 <td>Algebra</td> 157 <td>Equations & variables</td> 158 <td>Yield = f(water, fertilizer, sun)</td> 159 </tr> 160 <tr> 161 <td>Statistics</td> 162 <td>Understanding data</td> 163 <td>Average rainfall, yield variance</td> 164 </tr> 165 <tr> 166 <td>Calculus</td> 167 <td>Optimization</td> 168 <td>Finding optimal input levels</td> 169 </tr> 170 <tr> 171 <td>Linear Algebra</td> 172 <td>Data operations</td> 173 <td>Processing multiple farm variables</td> 174 </tr> 175 </table> 176 </div> 177 178 <div class="code-section"> 179 <h2>ð» Python Implementation</h2> 180 <pre><code class="language-python"> 181# Mathematical concepts applied to farming 182 183import math 184 185# 1. Simple Equation: Yield Prediction 186def predict_yield(rainfall, fertilizer, base_yield=2000): 187 """ 188 Simple linear model: Yield = base + (rain_effect) + (fert_effect) 189 This is the foundation of regression! 190 """ 191 rain_coefficient = 10 # kg per mm of rain 192 fert_coefficient = 15 # kg per unit of fertilizer 193 194 predicted = base_yield + (rainfall * rain_coefficient) + (fertilizer * fert_coefficient) 195 return predicted 196 197print("=== Yield Prediction (Linear Model) ===") 198print(f"100mm rain, 50 units fert: {predict_yield(100, 50)} kg/hectare") 199 200# 2. Optimization: Finding best input levels 201def profit_function(fertilizer_amount, price_per_kg=20, fert_cost_per_unit=50): 202 """ 203 Find fertilizer amount that maximizes profit 204 Yield increases with fertilizer but with diminishing returns 205 """ 206 # Diminishing returns: sqrt function 207 yield_increase = 500 * math.sqrt(fertilizer_amount) 208 209 revenue = yield_increase * price_per_kg 210 cost = fertilizer_amount * fert_cost_per_unit 211 profit = revenue - cost 212 213 return profit 214 215print("\\n=== Optimization: Best Fertilizer Amount ===") 216for fert in [10, 25, 50, 100, 150]: 217 profit = profit_function(fert) 218 print(f"Fertilizer: {fert} units -> Profit: â¹{profit:.0f}") 219 </code></pre> 220 </div> 221 222 <div class="student-activity"> 223 <h2>ð¯ Hands-On Activity</h2> 224 <div class="activity-box"> 225 <h3>Farm Math Challenge</h3> 226 <p>Calculate the following for your farm (or use sample data):</p> 227 <ol> 228 <li>If yield = 2000 + 15Ã(fertilizer), what yield do you get with 40 units of fertilizer?</li> 229 <li>Calculate the percentage increase in yield if you apply 50 units vs 30 units</li> 230 <li>If water costs â¹2/liter and you need 5000 liters/hectare, what's the cost for 3 hectares?</li> 231 </ol> 232 </div> 233 </div> 234 235 <div class="quiz-section"> 236 <h2>ð Knowledge Check</h2> 237 238 <div class="quiz-question"> 239 <p><strong>Q1:</strong> If Yield = 1500 + 20ÃFertilizer, what is the yield when Fertilizer = 30?</p> 240 <ul> 241 <li>A) 1500</li> 242 <li>B) 2100</li> 243 <li>C) 600</li> 244 <li>D) 2500</li> 245 </ul> 246 <details> 247 <summary>Show Answer</summary> 248 <p><strong>Answer: B</strong> - Yield = 1500 + 20Ã30 = 1500 + 600 = 2100</p> 249 </details> 250 </div> 251 </div> 252 253 <div class="summary"> 254 <h2>ð Key Takeaways</h2> 255 <ul> 256 <li>Math is the language ML uses to describe patterns</li> 257 <li>Algebra helps express relationships (yield = f(inputs))</li> 258 <li>Statistics helps understand data variability</li> 259 <li>Calculus helps find optimal solutions</li> 260 </ul> 261 </div> 262 </div> 263 `, 264 265 'm1-t7': ` 266 <div class="handout-premium"> 267 <div class="topic-header"> 268 <h1>ð¾ Statistics and Probability Basics</h1> 269 <p class="duration">â±ï¸ Duration: 3 hours</p> 270 </div> 271 272 <div class="learning-objectives"> 273 <h2>ð Learning Objectives</h2> 274 <ul> 275 <li>Calculate mean, median, and mode for agricultural data</li> 276 <li>Understand variance and standard deviation</li> 277 <li>Apply probability concepts to farming decisions</li> 278 <li>Interpret statistical summaries of farm data</li> 279 </ul> 280 </div> 281 282 <div class="farming-analogy"> 283 <h2>ð The Farming Connection</h2> 284 <div class="analogy-box"> 285 <p><strong>Statistics = The Voice of Your Farm's History</strong></p> 286 <p>ð <strong>Mean:</strong> Your average yield over 5 years</p> 287 <p>ð <strong>Variance:</strong> How much yields swing year to year</p> 288 <p>ð <strong>Probability:</strong> Chance of good monsoon this year</p> 289 </div> 290 </div> 291 292 <div class="core-concepts"> 293 <h2>ð Core Concepts</h2> 294 295 <h3>1. Measures of Central Tendency</h3> 296 <ul> 297 <li><strong>Mean:</strong> Sum of all values / count (average)</li> 298 <li><strong>Median:</strong> Middle value when sorted</li> 299 <li><strong>Mode:</strong> Most frequent value</li> 300 </ul> 301 302 <h3>2. Measures of Spread</h3> 303 <ul> 304 <li><strong>Range:</strong> Max - Min</li> 305 <li><strong>Variance:</strong> Average of squared differences from mean</li> 306 <li><strong>Standard Deviation:</strong> Square root of variance</li> 307 </ul> 308 309 <h3>3. Probability Basics</h3> 310 <ul> 311 <li><strong>Probability:</strong> Likelihood of an event (0 to 1)</li> 312 <li><strong>Independent Events:</strong> One doesn't affect another</li> 313 <li><strong>Conditional Probability:</strong> P(A given B)</li> 314 </ul> 315 </div> 316 317 <div class="code-section"> 318 <h2>ð» Python Implementation</h2> 319 <pre><code class="language-python"> 320# Statistics with Farm Data 321import statistics 322 323# Annual yields (kg/hectare) for past 5 years 324yields = [2500, 2800, 2200, 3000, 2700] 325 326print("=== Yield Statistics ===") 327print(f"Yields: {yields}") 328print(f"Mean: {statistics.mean(yields):.0f} kg/ha") 329print(f"Median: {statistics.median(yields):.0f} kg/ha") 330print(f"Std Dev: {statistics.stdev(yields):.0f} kg/ha") 331print(f"Range: {max(yields) - min(yields)}
331 kg/ha") 332 333# Probability calculation 334total_years = 10 335drought_years = 3 336prob_drought = drought_years / total_years 337print(f"\\nDrought Probability: {prob_drought:.0%}") 338 339# Variance interpretation 340if statistics.stdev(yields) > 300: 341 print("â ï¸ High variability - consider crop insurance!") 342else: 343 print("â Stable yields - good predictability") 344 </code></pre> 345 </div> 346 347 <div class="student-activity"> 348 <h2>ð¯ Hands-On Activity</h2> 349 <div class="activity-box"> 350 <h3>Calculate Your Farm Statistics</h3> 351 <p>Use the rainfall data for your village (or sample data):</p> 352 <p>Monthly rainfall (mm): [45, 60, 120, 180, 250, 320, 280, 200, 150, 80, 40, 30]</p> 353 <ol> 354 <li>Calculate mean monthly rainfall</li> 355 <li>Find the median</li> 356 <li>Which months are above average?</li> 357 <li>If good monsoon needs >200mm for 3 months, what's the probability?</li> 358 </ol> 359 </div> 360 </div> 361 362 <div class="quiz-section"> 363 <h2>ð Knowledge Check</h2> 364 365 <div class="quiz-question"> 366 <p><strong>Q1:</strong> For yields [2000, 2500, 2500, 3000], what is the mode?</p> 367 <ul> 368 <li>A) 2000</li> 369 <li>B) 2500</li> 370 <li>C) 2250</li> 371 <li>D) 3000</li> 372 </ul> 373 <details> 374 <summary>Show Answer</summary> 375 <p><strong>Answer: B</strong> - 2500 appears twice, more than any other value.</p> 376 </details> 377 </div> 378 379 <div class="quiz-question"> 380 <p><strong>Q2:</strong> If standard deviation is high, what does it mean for yield prediction?</p> 381 <ul> 382 <li>A) Very predictable yields</li> 383 <li>B) Yields vary a lot, harder to predict</li> 384 <li>C) All yields are the same</li> 385 <li>D) No relationship with prediction</li> 386 </ul> 387 <details> 388 <summary>Show Answer</summary> 389 <p><strong>Answer: B</strong> - High standard deviation means more variability, making predictions less certain.</p> 390 </details> 391 </div> 392 </div> 393 394 <div class="summary"> 395 <h2>ð Key Takeaways</h2> 396 <ul> 397 <li>Mean tells you the "typical" value</li> 398 <li>Standard deviation tells you how much values vary</li> 399 <li>Probability helps quantify uncertainty in farming</li> 400 <li>Statistics are the foundation of data-driven farming decisions</li> 401 </ul> 402 </div> 403 </div> 404 `, 405 406 'm1-t8': ` 407 <div class="handout-premium"> 408 <div class="topic-header"> 409 <h1>ð¾ Linear Algebra for Machine Learning</h1> 410 <p class="duration">â±ï¸ Duration: 3 hours</p> 411 </div> 412 413 <div class="learning-objectives"> 414 <h2>ð Learning Objectives</h2> 415 <ul> 416 <li>Understand vectors and matrices as data structures</li> 417 <li>Perform basic matrix operations</li> 418 <li>Connect linear algebra to ML computations</li> 419 </ul> 420 </div> 421 422 <div class="farming-analogy"> 423 <h2>ð The Farming Connection</h2> 424 <div class="analogy-box"> 425 <p><strong>Matrices = Your Farm's Data Spreadsheet</strong></p> 426 <p>Imagine a table where each row is a different plot, and columns are: Temperature, Rainfall, Soil pH, Fertilizer Applied, Yield</p> 427 <p>That table IS a matrix! Linear algebra helps us process all plots simultaneously.</p> 428 </div> 429 </div> 430 431 <div class="core-concepts"> 432 <h2>ð Core Concepts</h2> 433 434 <h3>1. Vectors</h3> 435 <p>A vector is a list of numbers: [temp, rain, pH, yield]</p> 436 <p>Example: Plot data = [28, 150, 6.5, 2800]</p> 437 438 <h3>2. Matrices</h3> 439 <p>A matrix is a 2D array - multiple vectors stacked:</p> 440 <pre> 441 Plot1: [28, 150, 6.5, 2800] 442 Plot2: [30, 120, 6.8, 2600] 443 Plot3: [26, 180, 6.2, 3000] 444 </pre> 445 446 <h3>3. Why ML Needs This</h3> 447 <ul> 448 <li>Data is stored as matrices</li> 449 <li>Model weights are vectors</li> 450 <li>Predictions = matrix à vector operations</li> 451 </ul> 452 </div> 453 454 <div class="code-section"> 455 <h2>ð» Python Implementation</h2> 456 <pre><code class="language-python"> 457import numpy as np 458 459# Farm data as matrix 460# Columns: Temp, Rainfall, Soil_pH, Fertilizer 461farm_data = np.array([ 462 [28, 150, 6.5, 50], # Plot 1 463 [30, 120, 6.8, 45], # Plot 2 464 [26, 180, 6.2, 60], # Plot 3 465 [29, 140, 6.6, 55] # Plot 4 466]) 467 468print("Farm Data Matrix:") 469print(farm_data) 470print(f"Shape: {farm_data.shape} (4 plots à 4 features)") 471 472# Vector operations - weights for yield prediction 473weights = np.array([10, 5, 100, 20]) # Importance of each feature 474 475# Matrix-vector multiplication = predictions 476base_yield = 1000 477predictions = base_yield + farm_data @ weights 478 479print("\\nPredicted Yields:") 480for i, pred in enumerate(predictions): 481 print(f"Plot {i+1}: {pred:.0f} kg/ha") 482 </code></pre> 483 </div> 484 485 <div class="student-activity"> 486 <h2>ð¯ Hands-On Activity</h2> 487 <div class="activity-box"> 488 <h3>Create Your Farm Matrix</h3> 489 <ol> 490 <li>Open Google Colab</li> 491 <li>Create a matrix with 5 plots and 3 features each</li> 492 <li>Calculate column means (average temp, average rain, etc.)</li> 493 <li>Find which plot has the highest sum of features</li> 494 </ol> 495 </div> 496 </div> 497 498 <div class="quiz-section"> 499 <h2>ð Knowledge Check</h2> 500 501 <div class="quiz-question"> 502 <p><strong>Q1:</strong> A dataset with 100 farms and 5 measurements each has what matrix shape?</p> 503 <ul> 504 <li>A) 5 à 100</li> 505 <li>B) 100 à 5</li> 506 <li>C) 500 à 1</li> 507 <li>D) 1 à 500</li> 508 </ul> 509 <details> 510 <summary>Show Answer</summary> 511 <p><strong>Answer: B</strong> - 100 rows (farms) à 5 columns (measurements)</p> 512 </details> 513 </div> 514 </div> 515 516 <div class="summary"> 517 <h2>ð Key Takeaways</h2> 518 <ul> 519 <li>Vectors represent single data points (one farm's measurements)</li> 520 <li>Matrices represent datasets (many farms' measurements)</li> 521 <li>ML models use matrix operations for efficient computation</li> 522 <li>NumPy is the Python library for matrix operations</li> 523 </ul> 524 </div> 525 </div> 526 `, 527 528 'm1-t9': ` 529 <div class="handout-premium"> 530 <div class="topic-header"> 531 <h1>ð¾ Data Types and Structures</h1> 532 <p class="duration">â±ï¸ Duration: 2 hours</p> 533 </div> 534 535 <div class="learning-objectives"> 536 <h2>ð Learning Objectives</h2> 537 <ul> 538 <li>Distinguish between structured and unstructured data</li> 539 <li>Understand time series data in agriculture</li> 540 <li>Work with different data formats (CSV, images, sensor data)</li> 541 </ul> 542 </div> 543 544 <div class="farming-analogy"> 545 <h2>ð The Farming Connection</h2> 546 <div class="analogy-box"> 547 <p><strong>Data Types = Different Crop Varieties</strong></p> 548 <p>Just as you handle wheat differently from tomatoes, different data types need different processing:</p> 549 <ul> 550 <li>ð <strong>Structured:</strong> Like graded, sorted produce - easy to process</li> 551 <li>ð· <strong>Images:</strong> Like raw produce - needs preprocessing</li> 552 <li>ð <strong>Time Series:</strong> Like seasonal data - has order/sequence</li> 553 </ul> 554 </div> 555 </div> 556 557 <div class="core-concepts"> 558 <h2>ð Core Concepts</h2> 559 560 <h3>1. Structured Data</h3> 561 <p>Organized in rows and columns (spreadsheets, databases)</p> 562 <ul> 563 <li>Soil test results</li> 564 <li>Yield records</li> 565 <li>Market prices</li> 566 </ul> 567 568 <h3>2. Unstructured Data</h3> 569 <p>No predefined format</p> 570 <ul> 571 <li>Leaf images for disease detection</li> 572 <li>Satellite/drone imagery</li> 573 <li>Weather station notes</li> 574 </ul> 575 576 <h3>3. Time Series Data</h3> 577 <p>Data points indexed by time</p> 578 <ul> 579 <li>Daily temperature readings</li> 580 <li>Monthly rainfall</li> 581 <li>Crop growth over weeks</li> 582 </ul> 583 </div> 584 585 <div class="code-section"> 586 <h2>ð» Python Implementation</h2> 587 <pre><code class="language-python"> 588# Working with different data types 589 590# 1. Structured Data (table-like) 591soil_data = { 592 'plot': ['A', 'B', 'C'], 593 'pH': [6.5, 7.0, 5.8], 594 'nitrogen': [80, 60, 90] 595} 596print("Structured Data:", soil_data) 597 598# 2. Time Series Data 599import datetime 600weather_series = [ 601 ('2024-01-01', 25, 0), 602 ('2024-01-02', 27, 5), 603 ('2024-01-03', 24, 12), 604] 605print("\\nTime Series (date, temp, rain):") 606for day in weather_series: 607 print(f" {day}") 608 609# 3. Unstructured Data Reference 610print("\\nImage data: stored as 3D arrays (height à width à colors)") 611print("Example shape: (224, 224, 3) for a 224Ã224 RGB image") 612 </code></pre> 613 </div> 614 615 <div class="student-activity"> 616 <h2>ð¯ Hands-On Activity</h2> 617 <div class="activity-box"> 618 <h3>Classify Your Farm Data</h3> 619 <p>List 5 types of data you collect (or would collect) on a farm.</p> 620 <p>For each, classify as: Structured, Unstructured, or Time Series</p> 621 </div> 622 </div> 623 624 <div class="quiz-section"> 625 <h2>ð Knowledge Check</h2> 626 627 <div class="quiz-question"> 628 <p><strong>Q1:</strong> A spreadsheet of monthly crop yields is what type of data?</p> 629 <ul> 630 <li>A) Unstructured</li> 631 <li>B) Structured + Time Series</li> 632 <li>C) Image data</li> 633 <li>D) Audio data</li> 634 </ul> 635 <details> 636 <summary>Show Answer</summary> 637 <p><strong>Answer: B</strong> - It's structured (table format) and time-indexed (monthly).</p> 638 </details> 639 </div> 640 </div> 641 642 <div class="summary"> 643 <h2>ð Key Takeaways</h2> 644 <ul> 645 <li>Structured data is organized in tables - easy to process</li> 646 <li>Unstructured data (images, text) needs special processing</li> 647 <li>Time series data has temporal dependencies</li> 648 <li>Most agricultural data combines all three types</li> 649 </ul> 650 </div> 651 </div> 652 `, 653 654 'm1-t10': ` 655 <div class="handout-premium"> 656 <div class="topic-header"> 657 <h1>ð¾ Data Collection Methods in Agriculture</h1> 658 <p class="duration">â±ï¸ Duration: 2 hours</p> 659 </div> 660 661 <div class="learning-objectives"> 662 <h2>ð Learning Objectives</h2> 663 <ul> 664 <li>Understand IoT sensors and their applications in farming</li> 665 <li>Learn about satellite and drone imagery for agriculture</li> 666 <li>Compare manual vs automated data collection methods</li> 667 <li>Evaluate data quality considerations</li> 668 </ul> 669 </div> 670 671 <div class="farming-analogy"> 672 <h2>ð The Farming Connection</h2> 673 <div class="analogy-box"> 674 <p><strong>
674Data Collection = The Eyes and Ears of Your Farm</strong></p> 675 <p>ð¡ï¸ <strong>Sensors:</strong> Like a thermometer that never sleeps</p> 676 <p>ð°ï¸ <strong>Satellites:</strong> Like having a helicopter view 24/7</p> 677 <p>ð <strong>Manual:</strong> Like your experienced farmer's observations</p> 678 </div> 679 </div> 680 681 <div class="core-concepts"> 682 <h2>ð Data Collection Methods</h2> 683 684 <h3>1. IoT Sensors</h3> 685 <table> 686 <tr><th>Sensor Type</th><th>Measures</th><th>Use Case</th></tr> 687 <tr><td>Soil Moisture</td><td>Water content %</td><td>Irrigation scheduling</td></tr> 688 <tr><td>Weather Station</td><td>Temp, humidity, rain</td><td>Climate monitoring</td></tr> 689 <tr><td>pH Sensor</td><td>Soil acidity</td><td>Fertilizer planning</td></tr> 690 <tr><td>NDVI Sensor</td><td>Plant health</td><td>Stress detection</td></tr> 691 </table> 692 693 <h3>2. Remote Sensing</h3> 694 <ul> 695 <li><strong>Satellites:</strong> Large area coverage, regular intervals</li> 696 <li><strong>Drones:</strong> High resolution, on-demand</li> 697 <li><strong>Applications:</strong> Crop health, water stress, yield estimation</li> 698 </ul> 699 700 <h3>3. Manual Collection</h3> 701 <ul> 702 <li>Soil samples for lab testing</li> 703 <li>Visual crop inspections</li> 704 <li>Yield measurements at harvest</li> 705 </ul> 706 </div> 707 708 <div class="code-section"> 709 <h2>ð» Python Implementation</h2> 710 <pre><code class="language-python"> 711# Simulating sensor data collection 712 713import random 714import datetime 715 716def simulate_soil_sensor(): 717 """Simulate IoT soil sensor readings""" 718 return { 719 'timestamp': datetime.datetime.now().isoformat(), 720 'moisture': random.uniform(20, 80), 721 'temperature': random.uniform(20, 35), 722 'ph': random.uniform(5.5, 7.5) 723 } 724 725# Collect hourly readings 726print("=== IoT Sensor Simulation ===") 727for hour in range(3): 728 reading = simulate_soil_sensor() 729 print(f"Hour {hour}: Moisture={reading['moisture']:.1f}%, " 730 f"Temp={reading['temperature']:.1f}°C, pH={reading['ph']:.1f}") 731 732# Data quality check 733def validate_sensor_data(reading): 734 """Check if sensor data is within valid ranges""" 735 issues = [] 736 if not (0 <= reading['moisture'] <= 100): 737 issues.append("Invalid moisture") 738 if not (5 <= reading['temperature'] <= 50): 739 issues.append("Invalid temperature") 740 if not (4 <= reading['ph'] <= 9): 741 issues.append("Invalid pH") 742 return issues if issues else ["Valid data"] 743 744print("\\nData Validation:", validate_sensor_data(simulate_soil_sensor())) 745 </code></pre> 746 </div> 747 748 <div class="student-activity"> 749 <h2>ð¯ Hands-On Activity</h2> 750 <div class="activity-box"> 751 <h3>Design Your Farm's Data Collection System</h3> 752 <ol> 753 <li>Choose a crop you want to monitor</li> 754 <li>List 5 data points you need to collect</li> 755 <li>For each, specify: What sensor/method, How often, Where to place</li> 756 <li>Estimate rough costs (research online)</li> 757 </ol> 758 </div> 759 </div> 760 761 <div class="quiz-section"> 762 <h2>ð Knowledge Check</h2> 763 764 <div class="quiz-question"> 765 <p><strong>Q1:</strong> Which is best for monitoring a 100-hectare farm daily?</p> 766 <ul> 767 <li>A) Manual inspection only</li> 768 <li>B) Satellites + IoT sensors</li> 769 <li>C) Paper records</li> 770 <li>D) Memory alone</li> 771 </ul> 772 <details> 773 <summary>Show Answer</summary> 774 <p><strong>Answer: B</strong> - Large-scale continuous monitoring needs automated systems.</p> 775 </details> 776 </div> 777 </div> 778 779 <div class="summary"> 780 <h2>ð Key Takeaways</h2> 781 <ul> 782 <li>IoT sensors enable continuous, automated monitoring</li> 783 <li>Satellites provide broad coverage; drones offer detail</li> 784 <li>Manual collection is still valuable for samples and validation</li> 785 <li>Data quality is crucial - validate sensor readings!</li> 786 </ul> 787 </div> 788 </div> 789 ` 790}; 791 792// Export for use by lecture system 793if (typeof window !== 'undefined') { 794 window.module1HandoutsPart2 = module1HandoutsPart2; 795}
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.