def crt_mdl_rsp(arySptExpInf, tplPngSize, aryMdlParams, varPar, strCrd='<STR_LIT>',<EOL>lgcPrint=True):
if varPar == <NUM_LIT:1>:<EOL><INDENT>aryMdlCndRsp = cnvl_2D_gauss(<NUM_LIT:0>, aryMdlParams, arySptExpInf,<EOL>tplPngSize, None, strCrd=strCrd)<EOL><DEDENT>else:<EOL><INDENT>lstMdlParams = np.array_split(aryMdlParams, varPar)<EOL>queOut = mp.Queue()<EOL>lstMdlTc = [None] * varPar<EOL>lstPrcs = [None] * varPar<EOL>if lgcPrint:<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>for idxPrc in range(<NUM_LIT:0>, varPar):<EOL><INDENT>lstPrcs[idxPrc] = mp.Process(target=cnvl_2D_gauss,<EOL>args=(idxPrc, lstMdlParams[idxPrc],<EOL>arySptExpInf, tplPngSize, queOut<EOL>),<EOL>kwargs={'<STR_LIT>': strCrd},<EOL>)<EOL>lstPrcs[idxPrc].Daemon = True<EOL><DEDENT>for idxPrc in range(<NUM_LIT:0>, varPar):<EOL><INDENT>lstPrcs[idxPrc].start()<EOL><DEDENT>for idxPrc in range(<NUM_LIT:0>, varPar):<EOL><INDENT>lstMdlTc[idxPrc] = queOut.get(True)<EOL><DEDENT>for idxPrc in range(<NUM_LIT:0>, varPar):<EOL><INDENT>lstPrcs[idxPrc].join()<EOL><DEDENT>if lgcPrint:<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>lstMdlTc = sorted(lstMdlTc)<EOL>aryMdlCndRsp = np.empty((<NUM_LIT:0>, arySptExpInf.shape[-<NUM_LIT:1>]))<EOL>for idx in range(<NUM_LIT:0>, varPar):<EOL><INDENT>aryMdlCndRsp = np.concatenate((aryMdlCndRsp, lstMdlTc[idx][<NUM_LIT:1>]),<EOL>axis=<NUM_LIT:0>)<EOL><DEDENT>del(lstMdlParams)<EOL>del(lstMdlTc)<EOL><DEDENT>return aryMdlCndRsp.astype('<STR_LIT>')<EOL>
Create responses of 2D Gauss models to spatial conditions.

    Parameters
    ----------
    arySptExpInf : 3d numpy array, shape [n_x_pix, n_y_pix, n_conditions]
        All spatial conditions stacked along second axis.
    tplPngSize : tuple, 2
        Pixel dimensions of the visual space (width, height).
    aryMdlParams : 2d numpy array, shape [n_x_pos*n_y_pos*n_sd, 3]
        Model parameters (x, y, sigma) for all models.
    varPar : int, positive
        Number of cores to parallelize over.
    strCrd, string, either 'crt' or 'pol'
        Whether model parameters are provided in cartesian or polar coordinates
    lgcPrint : boolean
        Whether print statements should be executed.

    Returns
    -------
    aryMdlCndRsp : 2d numpy array, shape [n_x_pos*n_y_pos*n_sd, n_cond]
        Responses of 2D Gauss models to spatial conditions.