Comments (8)
Hello @kvos ,
Thank you for the reply.
I forgot to mention, I was able to resolve the error.
Yes I have only one shoreline and as you said it should give the value for each transect.
The issue was with the length of the transects from on-shore to the shoreline intersection point.
The length for NA1 from on-shore to the shoreline intersection point was 1.207 KM, for NA2 it was 1.270 KM, NA3 it was 1.083 KM, NA5 it was 1.302 KM and NA4 it was 0.966 KM.
Then later I shorten the length of the transects and it was able to plot all subplots for 5 transect intersection points.
Then for confirmation I checked the python script for SDS_transects.py and on line 220 " idx_dist = np.logical_and(d_line <= settings['along_dist'], d_origin <= 1000)" this was mentioned as well on line 321 "idx_dist = np.logical_and(d_line <= along_dist, d_origin <= 1000)".
I think this was the reason it was only plotting for NA4.
Am I on the right track or something else was the reason for this to happen.
from coastsat.
Hi @jobthoma97
The reason you only see a single transect plotted is because only that transect intersected your shoreline. In the CSV the date represents the time the shoreline was captured and each column is the transect ID. All the transects except NA4 are blank which means they didn't intersect the shoreline captured in 2018. Without knowing your shoreline data I can't tell why that's the case, but I hope this helps!
It might be worth double checking that the shoreline and the transects are in the same CRS. I've made that mistake a lot.
from coastsat.
Hi @2320sharon ,
Thank you for replying.
I cross checked the CRS for transect and the CoastSat_Shoreline for 2018, they are both on the same CRS(32614).
I overlayed the transects and the output shoreline from CoastSat in QGIS, they intersect with the transects.
Below I have attached the Metadata, PDF FIle of the Jupyter Notebook and the output of shoreline overlayed on the transects.
Please have a look.
##-----------------Jupyter Script PDF File -------------------------------##
San_Jose_Texas.pdf
##-----------------Transect Metadata -------------------------------##
##-----------------Shoreline Metadata -------------------------------##
##-----------------Output File of Shoreline from CoastSat and Transect shapefile -------------------------------##
from coastsat.
hi @jobthoma97 , so you only have 1 shoreline mapped but you should get a value for each transect, not just NA4. Can you try to run the simple compute intersections? see what happens. I'm guessing some of the QC parameters is discarding the intersections for the other transects...
from coastsat.
that's exactly it, I had forgotten about that hard-coded 1km distance. Maybe we should increase it to 5km? we need to restrict it somehow as the equation we're using is point to line distance, which is not limited by distance and in case of someone putting transects that are not in the same coordinates as the shorelines it will give some false results. What do you think @2320sharon @jobthoma97 ?
from coastsat.
Absolutely.
And if there is a error message highlighting the transect length exceeded by 1 or 5km from on-shore to shoreline intersection points or the coordinates does not match, It will be easier for the users to identify the error or in the "example_Jupyter" a line can be added mentioning about the transect length range.
It's up to you, or there might be some better solutions.
Thank you very much @2320sharon and @kvos for the help.
from coastsat.
I'm happy I could help @jobthoma97 . I'm glad you got it all sorted out.
@kvos we've also run into issues with the hardcoded max distance of 1km in idx_dist = np.logical_and(d_line <= settings['along_dist'], d_origin <= 1000)
. Just like @jobthoma97 we couldn't figure out why we weren't getting shorelines with our long transects. I think having a new setting called something like max_distance_origin
to control this hard coded parameter would be useful. Some kind of log or error message to capture the points that were filtered out by idx_dist = np.logical_and(d_line <= settings['along_dist'], d_origin <= 1000)
could be helpful too.
from coastsat.
that's exactly it, I had forgotten about that hard-coded 1km distance. Maybe we should increase it to 5km? we need to restrict it somehow as the equation we're using is point to line distance, which is not limited by distance and in case of someone putting transects that are not in the same coordinates as the shorelines it will give some false results. What do you think @2320sharon @jobthoma97 ?
@kvos May I know what is the sole purpose of the hard-coded function to 1km . Just out of curiosity.
from coastsat.
Related Issues (20)
- Downloading question and reference shoreline question HOT 3
- Sentinel-2 images failed to download HOT 3
- CoastSat running on Colab: error with the pyfes package HOT 1
- L7 scanline error HOT 6
- Error about SDS_download.retrieve_images(inputs) HOT 1
- Coastsat to work for small atoll island of Tuvalu HOT 1
- Images not downloading HOT 6
- The meanings of the values before and after tidal adjustment, respectively. HOT 2
- Retrieve 2D tidally-corrected shoreline as shp/geojson HOT 1
- error while downloading HOT 6
- Tidal correction bug in example.py HOT 9
- Question: Why is ` n_intersect[i] = len(xy_rot[0, :])` used instead of `n_intersect[i] = np.sum(~np.isnan(xy_rot[0, :]))` in `compute_intersection_QC` HOT 3
- Clipping the output shorelines HOT 2
- SDS_preprocess issue HOT 9
- Nan values in cross distance HOT 4
- the change of slope HOT 2
- Unable to download images HOT 2
- CRSError: Invalid projection: EPSG:32756: (Internal Proj Error: proj_create: no database context specified) HOT 2
- Is it acceptable to use L7 data? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coastsat.