6. Create synthetic data

class kf.utils.createinput.SynteticKF(time, startdate=0)[source]

Class to initialise synthetic InSAR data to use with the Kalman Filter. It mirrors the functions of the class kf.readinput.SetupKF used for real observations.

  • timearray

    aquisitions times

build_R(rr, fmt)[source]
  • rrfloat

    variance (std**2) in observation (=interferograms) noise (float)

  • fmtstring

    define format of matrix R (‘diag’,’common_dates’,’num_links’)

create_interfero(rr, sig_i, t_sep=5, perp_dist=200, fmt='diag')[source]

Create interferograms for synthetic phases with temporal and perpendicular baseline constraints.

  • rrfloat

    variance in data (std**2)

  • sig_ifloat

    std of noise on phase differences

  • t_sepinteger, optional

    time separation allowed

  • perp_distfloat, optional

    separation of perp baseline (generated randomly with std 200) authorise

  • fmtstring, optional

    define format of matrix R (‘diag’,’common_dates’,’num_links’)

Returns:
  • interferograms (difference of phases)

  • covariance matrix of interferograms

  • the matrix of links between phases (# interf x # functional parameters and phases)

create_timeseries(model, m_r, sig_y, origintime=0.0, atmo=False)[source]

Create synthetic time series

  • modellist of tuples

    a model with the appropriate shape for the class TimeFct

  • m_rarray/list

    multiplicating factors for each element of the functional model

  • sig_yfloat

    std of noise on time series

  • origintimefloat, optional

    specify initial time if not zero

  • atmoboolean, optional

    add atmospheric noise? works for 2D only

Returns:
  • the reference phases (without noise)

  • the noisy phases

  • the array of reference parameters with sin and cos amplitudes

transformed into amplitude and phase shift of oscillation

get_interf_pairs()[source]

OBSOLETE as use pairs (15/10/2018) ? extract indices of phases substracted together to build interfero

  • imoins : indice of phases substracted to iplus (M)

  • iplus : indices of phases added (M)

slice_data(N_new)[source]

Slice previously generated array (Optional) (keeps same sequence of random numbers)

kf.utils.generateRnAtmo.generateAtmo(shape, sigma, lamb, nt=1)[source]

Generate synthetic atmospheric noise as the convolution of a white noise and a decreasing exponential.

  • shapeinteger or tuple of integers

    shape of 2D spatial grid

  • sigmafloat

    std of noise on one snapchot (e.g. 1.)

  • lambfloat

    spatial wavelength (e.g. 30.)

  • ntinteger, optional

    number of time snapchots

Returns noise map(s) with shape (shape,nt) if nt>1