3dbu

Members
  • Content count

    1,857
  • Joined

  • Last visited

  • Days Won

    10

3dbu last won the day on January 11

3dbu had the most liked content!

Community Reputation

160 Famous

1 Follower

About 3dbu

  • Rank
    Assistant Professor

Contact Methods

  • Website URL
    http://3dbu.blogspot.com/
  • Skype
    gisfuturo
  • MSN
    [email protected]

Profile Information

  • Gender
    Male
  • Location
    from hell
  • Interests
    GIS Analyst
  1. May be this link help you: https://www.researchgate.net/profile/T_Youd/publication/279600523_Mapping_liquefaction-induced_ground_failure_potential/links/5733901f08aea45ee838f8f2.pdf http://ascelibrary.org/doi/abs/10.1061/(ASCE)0733-9410(1990)116:2(244) regards.
  2. Pls share your result, regards
  3. amazing dude, sad becouse , only for crome support not for other browser , regards
  4. Nice jack_stepeny, i appreciated your help, and sure if have any question ,i'll contact to you, thank in advanced.
  5. thanks very much bro jack_stepeny, i 'll run the scripts , i appreciated your time and help for support and help , regards
  6. Cool, nice dude, if you can share the code in R will be welcome, thks in advanced and really bro i appreciate your help, regards.
  7. Thanks, jack_stepeny for your answer, all details are: 1) I have all data (raster file) in the same folder, 2) Each raster is named "prc_1971_01.tif" .and.."prc_1971_12.tif" for 12 month of the year, and the data is for 40 year ( 40 year x 12 month = 480 raster) fro this variable 3) I need made a raster for each year (summarized all raster of month for each year) and name it like "prc_1971.tif" in other word %prc_1971%, for each year. And i need made the scripts for do all process, is possible do you have any clue or idea...all idea are welcome. Thanks in advanced. I tested my scripts but still need to know how i make for read from a folder all raster and summarized each one month per each year ... import arcpy ... from arcpy.sa import * ... jn71 = arcpy.Raster("C:/prc.gdb/prc_1971_01") ... fr71 = arcpy.Raster("C:/prc.gdb/prc_1971_02") ... mr71 = arcpy.Raster("C:/prc.gdb/prc_1971_03") ... ab71 = arcpy.Raster("C:/prc.gdb/prc_1971_04") ... my71 = arcpy.Raster("C:/prc.gdb/prc_1971_05") ... jn71 = arcpy.Raster("C:/prc.gdb/prc_1971_06") ... jl71 = arcpy.Raster("C:/prc.gdb/prc_1971_07") ... ag71 = arcpy.Raster("C:/prc.gdb/prc_1971_08") ... st71 = arcpy.Raster("C:/prc.gdb/prc_1971_09") ... oc71 = arcpy.Raster("C:/prc.gdb/prc_1971_10") ... nv71 = arcpy.Raster("C:/prc.gdb/prc_1971_11") ... dc71 = arcpy.Raster("C:/prc.gdb/prc_1971_12") ... outraster = (jn71 + fr71 + mr71 + ab71 + my71 + jn71 + jl71 + ag71 + st71 + oc71 + nv71 + dc71) ... outraster.save ("C:/prc.gdb/prc_1971") ## Data 1972 process import arcpy ... from arcpy.sa import * ... jn72 = arcpy.Raster("C:/prc.gdb/prc_1972_01") ... fr72 = arcpy.Raster("C:/prc.gdb/prc_1972_02") ... mr72 = arcpy.Raster("C:/prc.gdb/prc_1972_03") ... ab72 = arcpy.Raster("C:/prc.gdb/prc_1972_04") ... my72 = arcpy.Raster("C:/prc.gdb/prc_1972_05") ... jn72 = arcpy.Raster("C:/prc.gdb/prc_1972_06") ... jl72 = arcpy.Raster("C:/prc.gdb/prc_1972_07") ... ag72 = arcpy.Raster("C:/prc.gdb/prc_1972_08") ... st72 = arcpy.Raster("C:/prc.gdb/prc_1972_09") ... oc72 = arcpy.Raster("C:/prc.gdb/prc_1972_10") ... nv72 = arcpy.Raster("C:/prc.gdb/prc_1972_11") ... dc72 = arcpy.Raster("C:/prc.gdb/prc_1972_12") ... outraster = (jn72 + fr72 + mr72 + ab72 + my72 + jn72 + jl72 + ag72 + st72 + oc72 + nv72 + dc72) ... outraster.save ("C:/prc.gdb/prc_1972") ## Data 1973 process import arcpy ... from arcpy.sa import * ... jn73 = arcpy.Raster("C:/prc.gdb/prc_1973_01") ... fr73 = arcpy.Raster("C:/prc.gdb/prc_1973_02") ... mr73 = arcpy.Raster("C:/prc.gdb/prc_1973_03") ... ab73 = arcpy.Raster("C:/prc.gdb/prc_1973_04") ... my73 = arcpy.Raster("C:/prc.gdb/prc_1973_05") ... jn73 = arcpy.Raster("C:/prc.gdb/prc_1973_06") ... jl73 = arcpy.Raster("C:/prc.gdb/prc_1973_07") ... ag73 = arcpy.Raster("C:/prc.gdb/prc_1973_08") ... st73 = arcpy.Raster("C:/prc.gdb/prc_1973_09") ... oc73 = arcpy.Raster("C:/prc.gdb/prc_1973_10") ... nv73 = arcpy.Raster("C:/prc.gdb/prc_1973_11") ... dc73 = arcpy.Raster("C:/prc.gdb/prc_1973_12") ... outraster = (jn73 + fr73 + mr73 + ab73 + my73 + jn73 + jl73 + ag73 + st73 + oc73 + nv73 + dc73) ... outraster.save ("C:/prc.gdb/prc_1973") So i need made this summarized but still i don't now how make the list raster and read all with made separate like i done, any idea!!! regards and thks in advanced
  8. Thanks, jack_stepeny for your answer, all details are: 1) I have all data (raster file) in the same folder, 2) Each raster is named "prc_1971_01.tif" .and.."prc_1971_12.tif" for 12 month of the year, and the data is for 40 year ( 40 year x 12 month = 480 raster) fro this variable 3) I need made a raster for each year (summarized all raster of month for each year) and name it like "prc_1971.tif" in other word %prc_1971%, for each year. And i need made the scripts for do all process, is possible do you have any clue or idea...all idea are welcome. Thanks in advanced.
  9. Hi community , i have a doubt , i need made a script in phyton that read a folder with 4800 raster in tif format, each raster is month and i need sum by month and year , i made a model builder for iterate just 12 raster x year and sum all, but my problem begin when i want to create a scripts that sum per year all raster and generate a raster for each year that summarized all raster for each month per year, in total are 40 year of data .... Anyone could give a idea for made that script completely in phyton, all idea are welcome. reagards .3dbu
  10. Could use any open source for share GIS data like web server or something like that for made the share ...regards
  11. nice paper, interest topic, useful for get better skill in temperature analyst with remote sensing, regards and good luck in the learning process.
  12. Check the Script of multi ring buffer: """---------------------------------------------------------------------------------- Tool Name: Multiple Ring Buffer Source Name: MultiRingBuffer.py Author: Environmental Systems Research Institute Inc. Required Arguments: An input feature class or feature layer An output feature class A set of distances (multiple set of double values) Optional Arguments: The name of the field to contain the distance values (default="distance") Option to have the output dissolved (default="ALL") Description: Creates a set of buffers for the set of input features. The buffers are defined using a set of variable distances. The resulting feature class has the merged buffer polygons with or without overlapping polygons maintained as separate features. ----------------------------------------------------------------------------------""" import arcpy import os import locale # Define message constants so they may be translated easily msgBuffRings = arcpy.GetIDMessage(86149) # "Buffering distance " msgMergeRings = arcpy.GetIDMessage(86150) # "Merging rings..." msgDissolve = arcpy.GetIDMessage(86151) # "Dissolving overlapping boundaries..." def initiate_multi_buffer(): """Gather arguments and set up for createMultiBuffers""" # Get the input argument values in_features = arcpy.GetParameterAsText(0) output = arcpy.GetParameterAsText(1) distances = arcpy.GetParameter(2) unit = arcpy.GetParameterAsText(3) if unit.lower() == 'default': unit = '' field_name = checkfieldname(arcpy.GetParameterAsText(4), os.path.dirname(output)) dissolve_type = arcpy.GetParameterAsText(5) outside_polygons = arcpy.GetParameterAsText(6) if outside_polygons.lower() == 'true': side_type = 'OUTSIDE_ONLY' else: side_type = '' create_multi_buffers(in_features, output, distances, unit, field_name, dissolve_type, side_type) def checkfieldname(field_name, workspace): """Validate field name on the workspace as needed""" if field_name in ['#', '']: return "distance" else: out_name = arcpy.ValidateFieldName(field_name, workspace) out_name = out_name.replace(' ', '_') if out_name != field_name: arcpy.AddIDMessage('WARNING', 648, out_name) return out_name def lower_license_union(feature_classes): """If Union is not licensed for more than 2 inputs at a time, perform Unions in batches""" union_fc = None tmp_fc = arcpy.Union_analysis( feature_classes[0:2], arcpy.CreateUniqueName('union', arcpy.env.scratchGDB))[0] for fc in feature_classes[2:]: if union_fc: tmp_fc = union_fc union_fc = arcpy.Union_analysis( [tmp_fc, fc], arcpy.CreateUniqueName('union', arcpy.env.scratchGDB))[0] # Delete intermediate data once used by next Union try: arcpy.Delete_management(tmp_fc) except arcpy.ExecuteError: # Don't fail for a delete issue pass return union_fc def create_multi_buffers(in_features, output, distances, unit, field_name, dissolve_type, side_type): """Main multiple ring buffer routine""" # Establish place holders for data cleanup buffer_list = [] union_fc = None try: # Loop through each distance creating a new layer and then buffering the input. # Set the step progressor if there are > 1 rings if len(distances) > 1: arcpy.SetProgressor('step', '', 0, len(distances)) step_progressor = True else: arcpy.SetProgressor('default') step_progressor = False # Buffer the input for each buffer distance. If the field_name is different than # the default, add a new field and calculate the proper value for dist in distances: if step_progressor: arcpy.SetProgressorPosition() arcpy.SetProgressorLabel(msgBuffRings + '{}...'.format(dist)) buf_distance = '{} {}'.format(dist, unit) buf_output = arcpy.Buffer_analysis(in_features, arcpy.CreateUniqueName('buffer', arcpy.env.scratchGDB), buf_distance, side_type, '', dissolve_type)[0] buffer_list.append(buf_output) if field_name.lower() != 'buff_dist': arcpy.AddField_management(buf_output, field_name, 'double') arcpy.CalculateField_management(buf_output, field_name, dist, 'PYTHON') arcpy.ResetProgressor() arcpy.SetProgressor('default') arcpy.SetProgressorLabel(msgMergeRings) if dissolve_type == 'ALL': # Set up the expression and codeblock variables for CalculateField to ensure # the distance field is populated properly expression = 'pullDistance({}, '.format(distances) for fc in buffer_list: expression += '!FID_{}!, '.format(os.path.basename(fc)) expression = expression[:-2] + ')' # If we have a full license then Union all feature classes at once, otherwise # Union the feature classes 2 at a time if arcpy.ProductInfo().upper() in ['ARCINFO', 'ARCSERVER'] or len(buffer_list) < 3: union_fc = arcpy.Union_analysis(buffer_list, arcpy.CreateUniqueName('union', arcpy.env.scratchGDB))[0] codeblock = '''def pullDistance(distL, *fids): return min([i for i, j in zip(distL, fids) if j != -1])''' else: union_fc = lower_license_union(buffer_list) codeblock = '''def pullDistance(distL, *fids): return min([i for i, j in zip(distL, fids) if j == 1])''' arcpy.CalculateField_management(union_fc, field_name, expression, 'PYTHON', codeblock) # Complete the final Dissolve arcpy.SetProgressorLabel(msgDissolve) if dissolve_type.upper() == 'ALL': arcpy.Dissolve_management(union_fc, output, field_name) else: # Reverse the order of the inputs so the features are appended from # largest to smallest buffer features. buffer_list.reverse() template = buffer_list[0] sr = (arcpy.env.outputCoordinateSystem or arcpy.Describe(template).spatialreference) arcpy.CreateFeatureclass_management(os.path.dirname(output), os.path.basename(output), 'POLYGON', template, 'SAME_AS_TEMPLATE', 'SAME_AS_TEMPLATE', sr) for fc in buffer_list: arcpy.Append_management(fc, output, 'NO_TEST') if arcpy.ListFields(output, 'buff_dist'): # Remove duplicate field arcpy.DeleteField_management(output, 'buff_dist') # Set the default symbology params = arcpy.GetParameterInfo() if len(params) > 0: params[1].symbology = os.path.join(arcpy.GetInstallInfo()['InstallDir'], "arctoolbox\\templates\\layers\\multipleringbuffer.lyr") except arcpy.ExecuteError: arcpy.AddError(arcpy.GetMessages(2)) except Exception as err: arcpy.AddError(err) finally: if buffer_list: for fc in buffer_list: try: arcpy.Delete_management(fc) except arcpy.ExecuteError: # Don't fail for a delete issue pass if union_fc: try: arcpy.Delete_management(union_fc) except arcpy.ExecuteError: # Don't fail for a delete issue pass if __name__ == '__main__': initiate_multi_buffer()
  13. Btw you can use a open source plugin in Qgis for made seem to drone2Arcgis , regards
  14. cool waiting for New Version of GISAREA forum, regards