Ziyuan111 commited on
Commit
6f30279
1 Parent(s): 8265a63

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +55 -0
README.md CHANGED
@@ -10,6 +10,20 @@ The `Class` is a custom dataset class that brings together information from two
10
  This class is designed to streamline the process of working with data from different sources and enable users to seamlessly access and analyze combined datasets.
11
  ## Project Overview
12
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
13
  The Durham Urban Canopy Analysis and Enhancement Initiative (DUCAEI) is committed to utilizing the Trees & Planting Sites dataset for a comprehensive geospatial analysis of Durham's urban tree canopy. Through Python within Google Colab, our aim is to identify key locations for canopy expansion, evaluate the impact of urban development on green spaces, and deliver informed recommendations for the sustainable growth of urban tree coverage.
14
 
15
  ## Background and Rationale
@@ -17,6 +31,47 @@ The Durham Urban Canopy Analysis and Enhancement Initiative (DUCAEI) is committe
17
  Durham's urban tree canopy is a crucial component that contributes to environmental quality, public health, and overall city aesthetics. This canopy is under threat due to ongoing urban development and natural wear. A systematic, data-driven approach is critical for strategic planning and conservation of the urban forest to ensure its vitality for generations to come.
18
 
19
  ## Data Sources and Methodology
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
 
21
  ### Data Sources
22
 
 
10
  This class is designed to streamline the process of working with data from different sources and enable users to seamlessly access and analyze combined datasets.
11
  ## Project Overview
12
 
13
+ {
14
+ "id": "your_dataset_id",
15
+ "title": "Durham Urban Canopy",
16
+ "description": "Your dataset description.",
17
+ "licenses": [
18
+ {
19
+ "name": "License Name",
20
+ "url": "URL to License"
21
+ }
22
+ ],
23
+ "image": "https://raw.githubusercontent.com/AuraMa111/Urban_Tree_Canopy_in_Durham/main/Picture1.png"
24
+ }
25
+
26
+
27
  The Durham Urban Canopy Analysis and Enhancement Initiative (DUCAEI) is committed to utilizing the Trees & Planting Sites dataset for a comprehensive geospatial analysis of Durham's urban tree canopy. Through Python within Google Colab, our aim is to identify key locations for canopy expansion, evaluate the impact of urban development on green spaces, and deliver informed recommendations for the sustainable growth of urban tree coverage.
28
 
29
  ## Background and Rationale
 
31
  Durham's urban tree canopy is a crucial component that contributes to environmental quality, public health, and overall city aesthetics. This canopy is under threat due to ongoing urban development and natural wear. A systematic, data-driven approach is critical for strategic planning and conservation of the urban forest to ensure its vitality for generations to come.
32
 
33
  ## Data Sources and Methodology
34
+ These data files are from durham open.
35
+
36
+ And for the .py file:
37
+
38
+ The provided Python script defines a dataset class named `DurhamTrees` using the `datasets` library. This class combines information from two different domains ("class1_domain1" and "class2_domain1") and includes features from both domains.
39
+
40
+ Key components of the script:
41
+
42
+ 1. **Imported Libraries:**
43
+ - `datasets`: for building the dataset.
44
+ - `pandas`: for handling data in tabular form.
45
+ - `geopandas`: for working with geospatial data.
46
+ - Other standard libraries for various functionalities.
47
+
48
+ 2. **URL Definitions:**
49
+ - Specifies URLs for CSV and GeoJSON files from two different domains.
50
+
51
+ 3. **DurhamTrees Class:**
52
+ - Inherits from `datasets.GeneratorBasedBuilder`.
53
+ - Defines configurations for two classes ("class1_domain1" and "class2_domain1").
54
+ - Specifies features for the combined dataset, including features from both classes.
55
+
56
+ 4. **Info Method:**
57
+ - Describes the combined dataset's features, supervised keys, homepage, and citation.
58
+
59
+ 5. **Split Generators Method:**
60
+ - Downloads and extracts data from the provided URLs.
61
+ - Defines split generators for training data.
62
+
63
+ 6. **Generate Examples Methods:**
64
+ - `_generate_examples`: Calls methods to generate examples for both classes.
65
+ - `_generate_examples_from_class1`: Reads CSV and GeoJSON data, merges them, and yields examples.
66
+ - `_generate_examples_from_class2`: Reads CSV data and yields examples.
67
+
68
+ 7. **Column Extraction:**
69
+ - Defines columns to extract for both classes, indicating which features to include in the final dataset.
70
+
71
+ 8. **Example Yielding:**
72
+ - Iterates over rows of the final dataframes, converting each row to a dictionary and yielding examples with unique identifiers.
73
+
74
+ The script is intended for creating a combined dataset from two different sources, and it uses the `datasets` library to facilitate data handling.
75
 
76
  ### Data Sources
77