CartesianToSpherical

class gwcs.geometry.CartesianToSpherical(wrap_lon_at=360, **kwargs)[source]

Bases: Model

Convert cartesian coordinates to spherical coordinates on a unit sphere. Output spherical coordinates are in degrees. When input cartesian coordinates are quantities (Quantity objects), output angles will also be quantities in degrees. Angle lon is the longitude (or azimuthal angle) in range [0, 360) (or [-180, 180)) and angle lat is the latitude (or elevation angle) in the range [-90, 90].

Parameters:
wrap_lon_at{360, 180}, optional

An integer number that specifies the range of the longitude (azimuthal) angle. When wrap_lon_at is 180, the longitude angle will have a range of [-180, 180) and when wrap_lon_at is 360 (default), the longitude angle will have a range of [0, 360).

Attributes Summary

n_inputs

The number of inputs.

n_outputs

The number of outputs.

wrap_lon_at

An integer number that specifies the range of the longitude (azimuthal) angle.

Methods Summary

__call__(*inputs[, model_set_axis, ...])

Evaluate this model using the given input(s) and the parameter values that were specified when the model was instantiated.

evaluate(x, y, z)

Evaluate the model on some input variables.

Attributes Documentation

n_inputs = 3

The number of inputs.

n_outputs = 2

The number of outputs.

wrap_lon_at

An integer number that specifies the range of the longitude (azimuthal) angle.

Allowed values are 180 and 360. When wrap_lon_at is 180, the longitude angle will have a range of [-180, 180) and when wrap_lon_at is 360 (default), the longitude angle will have a range of [0, 360).

Methods Documentation

__call__(*inputs, model_set_axis=None, with_bounding_box=False, fill_value=nan, equivalencies=None, inputs_map=None, **new_inputs)

Evaluate this model using the given input(s) and the parameter values that were specified when the model was instantiated.

evaluate(x, y, z)[source]

Evaluate the model on some input variables.