Пример #1
0
    def get(self):
        global gl
        # return gl
        file_id = request.args.get('id')
        ch1 = request.args.get('ch1')
        ch2 = request.args.get('ch2')
        transformation = request.args.get('transformation')
        bins = request.args.get('bins')
        gl = {
            'server_start_ts': dt.microsecond,
            'id': file_id,
            'ch1': ch1,
            'bins': bins,
            'transformation': transformation
        }
        if not file_id or not ch1 or not ch2:
            file_id = 'default'
            ch1 = 'HDR-T'
            ch2 = 'FSC-A'
            print('PLOTTING Default FCS and  chs', ch1, ch2)
        else:
            print('PLOTTING RECEIVED FCS and chs', file_id, ch1, ch2)

        plotting = Plotting(file_id, ch1, ch2, transformation, bins)
        plots = plotting.get_plots()
        gl.update(plots)
        return plots