spatially_sample_obsmetadata

rubin_sim.utils.spatially_sample_obsmetadata(obsmetadata, size=1, seed=1)

Sample a square patch on the sphere overlapping obsmetadata field of view by picking the area enclosed in obsmetadata.pointing_ra pm obsmetadata.bound_length obsmetadata.pointing_dec pm obsmetadata.bound_length

Parameters:
obsmetadatarubin_sim.utils.ObservationMetaData`
sizeint, optional, defaults to 1

number of samples

seedint, optional, defaults to 1

Random Seed used in generating random values

Returns:
ravals, thetavalsnp.ndarray, np.ndarray

tuple of ravals, decvalues in radians