আপনি Export.table ব্যবহার করে CSV, SHP (শেপফাইল), GeoJSON, KML, KMZ
বা TFRecord হিসেবে FeatureCollection এক্সপোর্ট করতে পারবেন। FeatureCollection ভেক্টর বা ডেটার
একটি সাধারণ টেবিলকে বোঝাতে পারে। পরের ক্ষেত্রে, কালেকশনের ফিচারগুলির
নাল জিওমেট্রি থাকবে।
কিছু ফাইলের ফরম্যাট নিয়ে কাজ করার সময় কিছু অতিরিক্ত সীমাবদ্ধতা লক্ষ্য করুন, যার মধ্যে রয়েছে:
- KML: KML ফাইলে এক্সপোর্ট করা
FeatureCollection-এর সব জিওমেট্রি আনপ্রোজেক্টেড (WGS84) কোঅর্ডিনেটে রূপান্তরিত হবে। - SHP: শেপফাইলে এক্সপোর্ট করা
FeatureCollection-এ একই জিওমেট্রি টাইপ ও প্রোজেকশন সহ ফিচার থাকতে হবে এবং শেপফাইলের সাইজের সীমার মধ্যে থাকতে হবে। কলামের নাম ১০টি বা তার কম অক্ষরে ট্রাঙ্কেট করা হয় এবং এর ফলে যেন ডুপ্লিকেট কলামের নাম তৈরি না হয়। - TFRecord: TFRecord ডেটা ফর্ম্যাট পৃষ্ঠা দেখুন।
Cloud Storage-এ
Cloud Storage-এ FeatureCollection এক্সপোর্ট করতে,
Export.table.toCloudStorage() ব্যবহার করুন। যেমন, আগে থেকে নির্ধারিত features ব্যবহার
করে:
কোড এডিটর (জাভাস্ক্রিপ্ট)
// Make a collection of points. var features = ee.FeatureCollection([ ee.Feature(ee.Geometry.Point(30.41, 59.933), {name: 'Voronoi'}), ee.Feature(ee.Geometry.Point(-73.96, 40.781), {name: 'Thiessen'}), ee.Feature(ee.Geometry.Point(6.4806, 50.8012), {name: 'Dirichlet'}) ]); // Export a KML file to Cloud Storage. Export.table.toCloudStorage({ collection: features, description:'vectorsToCloudStorageExample', bucket: 'your-bucket-name', fileNamePrefix: 'exampleTableExport', fileFormat: 'KML' });
import ee import geemap.core as geemap
Colab (Python)
# Make a collection of points. features = ee.FeatureCollection([ ee.Feature(ee.Geometry.Point(30.41, 59.933), {'name': 'Voronoi'}), ee.Feature(ee.Geometry.Point(-73.96, 40.781), {'name': 'Thiessen'}), ee.Feature(ee.Geometry.Point(6.4806, 50.8012), {'name': 'Dirichlet'}), ]) # Export a KML file to Cloud Storage. task = ee.batch.Export.table.toCloudStorage( collection=features, description='vectorsToCloudStorageExample', bucket='your-bucket-name', fileNamePrefix='exampleTableExport', fileFormat='KML', ) task.start()
অ্যাসেটে
Earth Engine অ্যাসেট হিসেবে FeatureCollection এক্সপোর্ট করতে,
Export.table.toAsset() ব্যবহার করুন। যেমন, আগে থেকে নির্ধারিত features ব্যবহার করে:
কোড এডিটর (জাভাস্ক্রিপ্ট)
// Export an ee.FeatureCollection as an Earth Engine asset. Export.table.toAsset({ collection: features, description:'exportToTableAssetExample', assetId: 'exampleAssetId', });
import ee import geemap.core as geemap
Colab (Python)
# Export an ee.FeatureCollection as an Earth Engine asset. task = ee.batch.Export.table.toAsset( collection=features, description='exportToTableAssetExample', assetId='projects/your-project/assets/exampleAssetId', ) task.start()
Earth Engine টেবিল অ্যাসেটের সাইজ ও আকারের উপর বেশ কিছু সীমাবদ্ধতা আছে:
- সর্বাধিক ১০০ মিলিয়ন ফিচার
- সর্বাধিক ১,০০০টি প্রপার্টি (কলাম)
- প্রতিটি সারির জ্যামিতির জন্য সর্বাধিক ১,০০,০০০ ভার্টিসেস
- প্রতিটি স্ট্রিং ভ্যালুতে সর্বাধিক ১,০০,০০০ অক্ষর থাকতে পারে
BigQuery-তে
Export.table.toBigQuery() ব্যবহার করে আপনি BigQuery টেবিলে FeatureCollection এক্সপোর্ট করতে পারবেন।
এটি আপনাকে BigQuery-তে উপলভ্য অন্যান্য ডেটা এবং টুলের সাথে আপনার Earth Engine ডেটা
ইন্টিগ্রেট করতে দেয়। আরও তথ্যের জন্য,
BigQuery-তে এক্সপোর্ট করার নির্দেশিকা দেখুন।
কোড এডিটর (জাভাস্ক্রিপ্ট)
Export.table.toBigQuery({ collection: features, table: 'myproject.mydataset.mytable', description: 'put_my_data_in_bigquery', append: true, overwrite: false });
import ee import geemap.core as geemap
Colab (Python)
task = ee.batch.Export.table.toBigQuery( collection=features, table='myproject.mydataset.mytable', description='put_my_data_in_bigquery', append=True, overwrite=False, ) task.start()
Drive-এ
আপনার Drive অ্যাকাউন্টে FeatureCollection এক্সপোর্ট করতে,
Export.table.toDrive() ব্যবহার করুন। যেমন:
কোড এডিটর (জাভাস্ক্রিপ্ট)
// Export the FeatureCollection to a KML file. Export.table.toDrive({ collection: features, description:'vectorsToDriveExample', fileFormat: 'KML' });
import ee import geemap.core as geemap
Colab (Python)
# Export the FeatureCollection to a KML file. task = ee.batch.Export.table.toDrive( collection=features, description='vectorsToDriveExample', fileFormat='KML' ) task.start()
মনে রাখবেন, ভৌগোলিক ডেটা ম্যানেজ করার জন্য আউটপুট ফর্ম্যাট KML হিসেবে নির্দিষ্ট করা হয়েছে (জ্যামিতি সহ টেবিল এক্সপোর্ট করার জন্য SHP-ও উপযুক্ত হবে)। কোনও ভৌগোলিক তথ্য ছাড়াই শুধু ডেটার টেবিল এক্সপোর্ট করতে, CSV ফর্ম্যাটে নাল জিওমেট্রি সহ ফিচার এক্সপোর্ট করুন। সম্ভাব্য দীর্ঘ সময় ধরে চলা রিডাকশনের ফলাফল পেতে
Export.table.toDrive() ব্যবহার করার পদ্ধতি নিচে দেখানো হল:
কোড এডিটর (জাভাস্ক্রিপ্ট)
// Load a Landsat image. var image = ee.Image('LANDSAT/LC08/C02/T1_TOA/LC08_044034_20140318'); var projection = image.select('B2').projection().getInfo(); // Create an arbitrary rectangle. var region = ee.Geometry.Rectangle(-122.2806, 37.1209, -122.0554, 37.2413); // Get a dictionary of means in the region. var means = image.reduceRegion({ reducer: ee.Reducer.mean(), geometry: region, crs: projection.crs, crsTransform: projection.transform, }); // Make a feature without geometry and set the properties to the dictionary of means. var feature = ee.Feature(null, means); // Wrap the Feature in a FeatureCollection for export. var featureCollection = ee.FeatureCollection([feature]); // Export the FeatureCollection. Export.table.toDrive({ collection: featureCollection, description: 'exportTableExample', fileFormat: 'CSV' });
import ee import geemap.core as geemap
Colab (Python)
# Load a Landsat image. image = ee.Image('LANDSAT/LC08/C02/T1_TOA/LC08_044034_20140318') projection = image.select('B2').projection().getInfo() # Create an arbitrary rectangle. region = ee.Geometry.Rectangle(-122.2806, 37.1209, -122.0554, 37.2413) # Get a dictionary of means in the region. means = image.reduceRegion( reducer=ee.Reducer.mean(), geometry=region, crs=projection['crs'], crsTransform=projection['transform'], ) # Make a feature without geometry and set the properties to the dictionary of means. feature = ee.Feature(None, means) # Wrap the Feature in a FeatureCollection for export. feature_collection = ee.FeatureCollection([feature]) # Export the FeatureCollection. task = ee.batch.Export.table.toDrive( collection=feature_collection, description='exportTableExample', fileFormat='CSV', ) task.start()
মনে রাখবেন, এই উদাহরণে ফর্ম্যাট 'CSV' হিসেবে সেট করা হয়েছে কারণ আউটপুটে কোনও জিওমেট্রি নেই।