28.1.16. Raster Creation
28.1.16.1. Create constant raster layer
Generates raster layer for given extent and cell size filled with the specified value.
Additionally an output data type can be specified. The algorithm will abort if a value has been entered that cannot be represented by the selected output raster data type.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Constant value |
|
[number] Default: 1 |
Constant pixel value for the output raster layer. |
Constant |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 5 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Constant |
|
[raster] |
Raster covering the desired extent with the specified pixel size and value. |
Python code
Algorithm ID: native:createconstantrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.2. Create random raster layer (binomial distribution)
Generates a raster layer for given extent and cell size filled with binomially distributed random values.
By default, the values will be chosen given an N of 10 and a probability of 0.5. This can be overridden by using the advanced parameter for N and probability. The raster data type is set to Integer types (Integer16 by default). The binomial distribution random values are defined as positive integer numbers. A floating point raster will represent a cast of integer values to floating point.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 0 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
N |
|
[number] Default: 10 |
|
Probability |
|
[number] Default: 0.5 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with random values |
Python code
Algorithm ID: native:createrandombinomialrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.3. Create random raster layer (exponential distribution)
Generates a raster layer for given extent and cell size filled with exponentially distributed random values.
By default, the values will be chosen given a lambda of 1.0. This can be overridden by using the advanced parameter for lambda. The raster data type is set to Float32 by default as the exponential distribution random values are floating point numbers.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 0 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Lambda |
|
[number] Default: 1.0 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with random values |
Python code
Algorithm ID: native:createrandomexponentialrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.4. Create random raster layer (gamma distribution)
Generates a raster layer for given extent and cell size filled with gamma distributed random values.
By default, the values will be chosen given an alpha and beta value of 1.0. This can be overridden by using the advanced parameter for alpha and beta. The raster data type is set to Float32 by default as the gamma distribution random values are floating point numbers.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 0 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Alpha |
|
[number] Default: 1.0 |
|
Beta |
|
[number] Default: 1.0 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with randomly distributed values |
Python code
Algorithm ID: native:createrandomgammarasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.5. Create random raster layer (geometric distribution)
Generates a raster layer for given extent and cell size filled with geometrically distributed random values.
By default, the values will be chosen given a probability of 0.5. This can be overridden by using the advanced parameter for mean value. The raster data type is set to Integer types (Integer16 by default). The geometric distribution random values are defined as positive integer numbers. A floating point raster will represent a cast of integer values to floating point.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 0 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Probability |
|
[number] Default: 0.5 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with randomly distributed values |
Python code
Algorithm ID: native:createrandomgeometricrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.6. Create random raster layer (negative binomial distribution)
Generates a raster layer for given extent and cell size filled with negative binomially distributed random values.
By default, the values will be chosen given a distribution parameter k of 10.0 and a probability of 0.5. This can be overridden by using the advanced parameters for k and probability. The raster data type is set to Integer types (Integer16 by default). The negative binomial distribution random values are defined as positive integer numbers. A floating point raster will represent a cast of integer values to floating point.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 0 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Distribution parameter k |
|
[number] Default: 10 |
|
Probability |
|
[number] Default: 0.5 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with randomly distributed values |
Python code
Algorithm ID: native:createrandomnegativebinomialrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.7. Create random raster layer (normal distribution)
Generates a raster layer for given extent and cell size filled with normally distributed random values.
By default, the values will be chosen given a mean of 0.0 and a standard deviation of 1.0. This can be overridden by using the advanced parameters for mean and standard deviation value. The raster data type is set to Float32 by default as the normal distribution random values are floating point numbers.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 0 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Mean of normal distribution |
|
[number] Default: 0.0 |
|
Standard deviation of normal distribution |
|
[number] Default: 1.0 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with randomly distributed values |
Python code
Algorithm ID: native:createrandomnormalrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.8. Create random raster layer (poisson distribution)
Generates a raster layer for given extent and cell size filled with poisson distributed random values.
By default, the values will be chosen given a mean of 1.0. This can be overridden by using the advanced parameter for mean value. The raster data type is set to Integer types (Integer16 by default). The poisson distribution random values are positive integer numbers. A floating point raster will represent a cast of integer values to floating point.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 0 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Mean |
|
[number] Default: 1.0 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with randomly distributed values |
Python code
Algorithm ID: native:createrandompoissonrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.
28.1.16.9. Create random raster layer (uniform distribution)
Generates a raster layer for given extent and cell size filled with random values.
By default, the values will range between the minimum and maximum value of the specified output raster type. This can be overridden by using the advanced parameters for lower and upper bound value. If the bounds have the same value or both are zero (default) the algorithm will create random values in the full value range of the chosen raster data type. Choosing bounds outside the acceptable range of the output raster type will abort the algorithm.
Parameters
Basic parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Desired extent |
|
[extent] |
Specify the spatial extent of the output raster layer. It will internally be extended to a multiple of the tile size. Available methods are:
|
Target CRS |
|
[crs] Default: Project CRS |
CRS for the output raster layer |
Pixel size |
|
[number] Default: 1.0 |
Pixel size (X=Y) in map units. |
Output raster |
|
[raster] Default: |
Specification of the output raster. One of:
|
Advanced parameters
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster data type |
Default: 5 |
[enumeration] |
Defines the data type of the output raster file. Options:
|
Lower bound for random number range |
|
[number] Default: 0.0 |
|
Upper bound for random number range |
|
[number] Default: 0.0 |
Outputs
Label |
Name |
Type |
Description |
---|---|---|---|
Output raster |
|
[raster] |
Raster covering the desired extent with the cell size filled with randomly distributed values |
Python code
Algorithm ID: native:createrandomuniformrasterlayer
import processing
processing.run("algorithm_id", {parameter_dictionary})
The algorithm id is displayed when you hover over the algorithm in the Processing Toolbox. The parameter dictionary provides the parameter NAMEs and values. See Using processing algorithms from the console for details on how to run processing algorithms from the Python console.