Skip to main content

VectorFieldRenderer

Краткая информация

Визуализирует информацию о направлении и величине потока в растре с помощью векторных символов.

Обсуждение

Указанный набор растровых данных является временным для растрового объекта. Чтобы сделать его постоянным, вы можете вызвать метод растрового объекта save.

Синтаксис

VectorFieldRenderer(raster, {is_uv_components}, {reference_system}, {mass_flow_angle_representation}, {calculation_method}, {symbology_name})

Параметр Объяснение Тип данных

raster

The input raster.

Raster

is_uv_components

Specifies whether the input components represent U-V, or magnitude and direction.

  • True—The input data represents U-V components.

  • False—The input data represents magnitude and direction components. This is the default.

(Значение по умолчанию — None)

Boolean

reference_system

Specifies how the direction component is measured.

  • 1—Direction is measured in arithmetic coordinates. 0° points due east, and 90° points due north.

  • 2—Direction is measured in geographic coordinates. 0° points due north, and 90° points due east.

(Значение по умолчанию — 2)

Integer

mass_flow_angle_representation

Specifies the angle of mass flow.

  • 0—From—The mass is flowing along the angle and moving toward the origin of the reference system. This is sometimes referred to as the meteorological convention.

  • 1—To—The mass is flowing along the angle and moving away from the origin of the reference system. This is sometimes referred to as the oceanographic convention.

(Значение по умолчанию — From)

Integer

calculation_method

Specifies the thinning method to be used to calculate the magnitude and direction value of a tile.

  • Vector Average—The following calculation occurs for each pixel: convert direction and magnitude to U and V components, calculate the averages of U and V for all pixels in a tile, and then convert the average U and average V back to direction and magnitude.

  • Nearest neighbor—Uses the value from the pixels closest to the center of the tile.

  • Bilinear—Bilinear resampling will be performed on the tile.

  • Cubic—Cubic convolution resampling will be performed on the tile.

  • Minimum—The minimum pixel value of the tile.

  • Maximum—The maximum pixel value of the tile.

(Значение по умолчанию — Vector Average)

String

symbology_name

Specifies the name of the symbol depicting direction and magnitude.

  • Single Arrow—A single arrow depicting direction and magnitude.

  • Wind Barb—Wind barbs indicating wind direction and magnitude.

  • Ocean Current—Ocean current symbol indicating current and magnitude.

(Значение по умолчанию — Single Arrow)

String

Возвращаемое значение

Тип данных Объяснение

Raster

Выходной растр показывается в соответствии с вашими параметрами отображения.

Пример кода

VectorFieldRenderer, пример

Визуализирует информацию о направлении и величине потока в растре с помощью векторных символов.

import arcpy

Stretch_raster = arcpy.ia.Stretch(imagePath1, "PercentClip", None, None, None, None, True, 0.25, 0.75, None, None, None)