Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SEDONA-30] Add raster data support in Sedona SQL #523

Merged
merged 81 commits into from
Jun 17, 2021

Conversation

shantanuaggarwal2695
Copy link
Contributor

@shantanuaggarwal2695 shantanuaggarwal2695 commented May 14, 2021

Is this PR related to a proposed Issue?

https://issues.apache.org/jira/projects/SEDONA/issues/SEDONA-30

What changes were proposed in this PR?

Three different constructors have been added :

  1. ST_GeomFromRaster - It fetches polygonal coordinates from raster image
  2. ST_GeomWithBandsFromGeoTiff - It constructs a data frame from a raster image with a fixed schema (Geometry and band values)
  3. ST_GetBand - Fetches a particular band value from the result of ST_DataframeFromRaster

How was this patch tested?

Patch has been tested using the Hadoop mini-cluster. Some more test cases can be added

Did this PR include necessary documentation updates?

Yes

core/pom.xml Outdated
@@ -60,6 +60,11 @@
</exclusion>
</exclusions>
</dependency>
<dependency>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please move all geotools dependency to the parent pom. See here: https://github.com/apache/incubator-sedona/blob/master/pom.xml#L120

Make sure you use the geotools scope variable for the scope

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

pom.xml Outdated Show resolved Hide resolved
@@ -26,7 +26,7 @@ import org.apache.spark.sql.catalyst.expressions.Expression
import org.apache.spark.sql.catalyst.expressions.codegen.CodegenFallback
import org.apache.spark.sql.catalyst.util.GenericArrayData
import org.apache.spark.sql.sedona_sql.UDT.GeometryUDT
import org.apache.spark.sql.types.{DataType, Decimal}
import org.apache.spark.sql.types._
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this change is not necessary, do not commit this change. You can replace the "_" with the original content

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@jiayuasu jiayuasu changed the title [SEDONA-30] Add ST_GeomFromRaster, ST_GeomWithBandsFromGeoTiff and RS_GetBand in Sedona [SEDONA-30] Add raster data support in Sedona SQL Jun 17, 2021
@jiayuasu jiayuasu merged commit 8fd688f into apache:master Jun 17, 2021
@jiayuasu jiayuasu deleted the main_thesis branch June 17, 2021 09:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants