#NEWLINE# def generate_plates( seed , world_name , output_dir , width , height , num_plates = 10 ) : #NEWLINE# #INDENT# '\n    Eventually this method should be invoked when generation is called at\n    asked to stop at step "plates", it should not be a different operation\n    :param seed:\n    :param world_name:\n    :param output_dir:\n    :param width:\n    :param height:\n    :param num_plates:\n    :return:\n    ' #NEWLINE# ( elevation , plates ) = generate_plates_simulation ( seed , width , height , num_plates = num_plates ) #NEWLINE# world = World ( world_name , Size ( width , height ) , seed , GenerationParameters ( num_plates , ( - 1.0 ) , 'plates' ) ) #NEWLINE# world . set_elevation ( numpy . array ( elevation ) . reshape ( height , width ) , None ) #NEWLINE# world . set_plates ( numpy . array ( plates , dtype = numpy . uint16 ) . reshape ( height , width ) ) #NEWLINE# filename = ( '%s/plates_%s.png' % ( output_dir , world_name ) ) #NEWLINE# draw_simple_elevation_on_file ( world , filename , None ) #NEWLINE# print ( ( "+ plates image generated in '%s'" % filename ) ) #NEWLINE# geo . center_land ( world ) #NEWLINE# filename = ( '%s/centered_plates_%s.png' % ( output_dir , world_name ) ) #NEWLINE# draw_simple_elevation_on_file ( world , filename , None ) #NEWLINE# print ( ( "+ centered plates image generated in '%s'" % filename ) )