POST
|
Hi every one, I'm having trouble figuring these features out. They've been highly recommended, but I find the normal tools to be easier and usually give up my experimenting. However, I'm getting larger datasets where working in a mosaic dataset (MDS) would be beneficial. I've had a lot of different problems, but the issues I'm having presently pertain to referenced MDSs not synchronizing when I add new raster layers to their source (this includes not updated the image or the applied raster functions), and some raster functions not working in a referenced MDS (I get these to work in the source MDS by rebuilding overviews, which I can't do to the reference). I've been using these ESRI pages primarily (below) with some success, as well as other forum posts and questions, but they either don't explain the workflow in much detail or seem to not address the same issues I'm having. Create Referenced Mosaic Dataset—Help | ArcGIS for Desktop Synchronizing a mosaic dataset—Help | ArcGIS for Desktop Synchronize Mosaic Dataset—Help | ArcGIS for Desktop For example, if I have a MDS for an elevation DEM and a referenced MDS created from it to apply hillshade and I add a new layer to the elevation one it will update with the new layer, but the hillshade won't. If I try using the synchronize tool it throws a 'partial overview' error. For the other issue, the statistics function ouputs a grey box that is fixed by building overviews again on the source (elevation in the example), but it won't work this way if I have statistics set up for a referenced MDS. An obvious fix would be to make separate MDSs for each thing I need to run, but this seems overly redundant. If the functions are being applied to the same set of DEMs it makes more sense to have the source DMS be the elevation layers, and referenced layers be the applied functions to make hillshade, slope, standard deviation, etc. Another possibility I've seen and tried to apply is I'm missing something in the Function Chain, but in my experimenting so far I've mostly been doing one step things (like slope and hillshade); though I have gotten some more complicated chains to work, they run into the same issue as the first question above, where they don't update with new layers if I add any to the source MDS. Any insight would be greatly appreciated. I'm not sure where to ask these questions either; apologies if I put it in the wrong group. Cheers, Nate
... View more
06-08-2017
10:46 AM
|
0
|
0
|
601
|
POST
|
I see the same issue with some function output. I suspect it has to do with the stretch being Min to Max, and those values change when you change the view window (either by zooming or moving it around). I don't know how to set a MDS wide standard range though. I'm still learning the MDS feature and raster functions.
... View more
06-08-2017
10:12 AM
|
0
|
1
|
471
|
POST
|
In effect, I am mapping wells from LIDAR (Attch: "Desired_map_outp"). I have processed the dems to show differences in depth, and overlay those over the dems. I am looking at a region with multiple sites, each with multiple tiles. Sites were mosaic'ed, now I want to give them a standard symbology so they can be more easily compared. I applied symbology to multiple rasters using Apply Symbology to Layer (ASTL) in Arcpy; the intent is to apply a constant symbology (Attach: "Master Symbology") to many study site mosaics so they can be compared in figures with one common legend. Though the code ran and finished the output has two problems, one of which I may have fixed. The code applied colors and range correctly, but reversed the label relative to the range (Attach: "Issue_1") (the legend displays the max value on the true minimum - desired colors properly applied to min-max). To fix this I reversed the Range and Symbol columns in Symbology tab for the master layer and tested with the ASTL; I am doing depths of wells and initially reversed them to have 0 on top, and depth downwards; which seems to have caused the error). The other error that I can't figure out how to fix is Range assignment over the entire collection. I made the master layer from the mosaic I believe has the min (0 relative to surface) and max depths (Atch: "Master Symbology"). However, when I applied this symbology with ASTL in arcpy, and with the tool itself to single layers, the result only covered the range of the target raster. That being, I want a min of 0 and max of -60, with 20 bins/classes and color gradient (for example) of yellow to blue (with orange, red, purple intermediates; with some manual changes to green), this is what the master is set to. Target rasters of -0.1 to -12.0 for example, will break into 20 classes/bins and apply the gradient but only at a range of -0.1 to -12.0 (Atch: "Target Layers"); I want it to force a range of 0 to -60, and only display its values on map of -0.1 to -12. An alternative to forcing the full range on each receiving raster would be to end the reduce the number of bins/classes, and cut off the color gradient at its depth relative to the master so that they have the same relative depth classes and colors. This seems more difficult to automate over many rasters with different min-max values though. Automation is also a necessity, as I have ~80+ mosaics I'm currently trying to symbolize, and many more rasters of different locations that will be processed and need symbolized later. I wasn't able to force a range wider than what a raster had, and hoped it could be achieved with the ASTL tool, but as above am having issues. Any help would be appreciated. Cheers, Nate Code for record. Not sure if this is exactly what I did before as I was importing and grouping layers as well, but a close recreation of the symbolization I was trying to get. >>> import arcpy ... mxd = arcpy.mapping.MapDocument("Current") ... df=arcpy.mapping.ListDataFrames(mxd)[0] ... depthLyrs=arcpy.mapping.ListLayers(mxd,"depth*",df) ... mastLyr=arcpy.mapping.ListLayers(mxd,"*symBeta",df) ... >>> for lyr in depthLyrs: ... arcpy.ApplySymbologyFromLayer_management(lyr, mastLyr) ... arcpy.RefreshTOC() ... arcpy.RefreshActiveView()
... View more
01-30-2017
08:50 AM
|
0
|
0
|
962
|
POST
|
I had given up on trying to do it in model builder and did the Python for Everyone tutorial to get a grasp of it. Then using forums I was able to piece together a code that worked. It was perhaps more complicated than it needed to be trying to get conditionals to work depending on the name of files as I have two sets for each site; the normal dem, and a processed dem to overlay and show depth of holes (essentially wells in the study areas). Model builder was great for processing the dem's into the overlays I needed. But for mosaicing together, since I had so many conditionals I wanted to impose it was easier to mosaic in arcpy with if statements (which in plotting this out I had several more and realized it was inefficient so I condensed it by the time I made this image). Apologies for the amateur code; I'm still very new to arcpy and python and haven't done any other coding for over six years. Output looked kind of like this:: Adding rasters to list: site1_tile1 site1_tile2 site1_tile3 List done; mosaicing tiles from list. Reset list to empty and start new site (it was important to reset the list "rasters=[]" at the bottom of the code each time otherwise it would have just added site 2 to the end of site 1 list and mosaiced both sites together). Adding rasters to list: site2_tile1 site2_tile2>>>>>> To test it I ran the entire process as print " " statements as above and left the mosaic tool in comment (#arcpy.mapping....) so it wouldn't take as long to test. Once the raster lists contained only raster tiles from a single site, and reset properly only including the next site, I ran it through with mosaic uncommented. I realized I deleted the tile sets after the mosaic finished to save hard drive space (as I have several redundant backups of them elsewhere) so I can't run it again and show the exact results. Apologies if the pathnames are confusing. I have to get permission to publish anything with the actual dems and to avoid any issues I altered the pathnames that included them just incase. And, now that those are done I'm trying to figure out how to use ArcPy to add layers to an mdx, set them into layer groups, and apply standard symbologies from an IDE; will probably be making a separate post on that soon as I'm having dificulty with it. Thanks for all your help Curtis! Cheers, Nate
... View more
01-22-2017
10:29 AM
|
2
|
0
|
493
|
POST
|
Making as a dedicated thread originated in comments here with @Duncan Hornby and @Curtis Price. Need: I have many sites each composed of one to over twenty rasters. They are sorted into folders by site (Atch: "Folder Structure"). I want to iterate through these sites as workspaces in order to mosaic rasters in each site. Output will be in a different folder titled as such: "mosaic_siteX" or "siteX_mosaic". Model Attempts: I first tried a 3 part model; one to iterate workspaces, one to iterate rasters in those workspaces, and one to perform the mosaic (Atch: "TestModel_1"). I ran the iterate workspaces feeding the folder containing the sites with "recursive" checked. This, in a way, was the most successful attempt, though it didn't work. It would iterate through all the workspaces and only mosaic the last one, but it mosaic'ed this last correctly. Changing the above per suggestions in thread linked at top I moved the nest to be m2 inside of m1 (instead of vice versa) and sent that output to a third for mosaicing (Atch: "TestModel_2"). This output iterated through workspaces but only sent the last tile of each site workspace to the Collect Values tool and mosaic'ed the last tile of each site together rather than all tiles from one site together. I tried a third edit, running the mosaic inside m1 after the collect values, but this had similar results to directly above. It would iterate through and make a mosaic each iteration, each time adding the last tile of the next site added. I.e. first iteration last tile of site 2; second iteration last tile of site 2 and 5 mosaic together; third iteration last tile of site 2, 5, 6 mosaic together. I need to blend the mistakes, as it were. The iterate rasters to collect values and mosaic results need to be that of the first attempt, but the site folders and workspace iteration needs to do that mosaic to all folders, not just the last one. I want to try and finish this in model builder, as that is where I have had the most successful experimenting thus far. If it comes down to it I may try to use arcpy, but my exposure is limited for the moment; I will be taking a class on it starting next week. Apologies for the delay in getting this post up. I've had power and internet issues following a local incident in town the other day. Cheers, Nate
... View more
01-13-2017
09:09 AM
|
0
|
2
|
2088
|
POST
|
Thanks Duncan, I will start a new thread for this. Your recommendation seems the most promising of the suggestions within my current knowledge set. I'm taking a class on Python starting next week and will get more into using it; until then, of all my experimenting I've had most success with model builder so I'll stick with that the rest of the week. I ran the model from here, and edited it further; I'll cover in a dedicated thread. Cheers, Nate
... View more
01-11-2017
01:14 PM
|
0
|
0
|
888
|
POST
|
Hi Xander, I spent a lot of time trying to get the mosaic dataset tools to work, but had trouble. I couldn't figure out for certain where the issue was; it seemed to occur when I added a raster to it that overlapped a different one, then tiles went grey and overviews would not rebuild. At the moment I'm only using the mosaic dataset to create the footprints because its the only aspect I can get to work on a regular basis. As per Duncan's note on best practice I will make a new question thread when next I try to use the Mosaic Datasets. Cheers, Nate
... View more
01-11-2017
10:29 AM
|
1
|
0
|
888
|
POST
|
Apologies if I should ask this in a new thread. I am having issues with a similar workflow. I have dem data for several different sites, each with several tiles covering the areas. I want to mosaic each site individually rather than the entire data set. Trying to follow the workflows discussed above, I'm using one submodel to iterate each site folder as a current workspace (1) within another submodel iterating that workspace's rasters into the collect values tool (2), then passing that into the master model that runs the mosaic on the given site's raster list (3), then hopefully starting over and running the next site through all steps in the model chain. My problem is it seems the workspace and or raster iterator is running and only sending the last site file on to the mosaic tool in (3). I.e. If I have site 2 alone it will mosaic site 2 properly; if I add site 5 to the test folder it will only output a mosaic of site 5's tiles (though it does that site properly). Similar if I add site 6 it will skip 2 and 5 and only output site6_mosaic. I'm just doing small folder sets as a test, there's a lot more, hence I'm trying to figure out the model to iterate all of it.
... View more
01-10-2017
03:52 PM
|
0
|
5
|
2473
|
Title | Kudos | Posted |
---|---|---|
1 | 01-11-2017 10:29 AM | |
2 | 01-22-2017 10:29 AM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:24 AM
|