def main(): sys.excepthook = logUncaughtExceptions app = qt.QApplication([]) widget = CalibrationWindow() setup(widget.model()) widget.setVisible(True) app.exec_()
def main(): dt = DiffMap() options, config = dt.parse(with_config=True) if not options.gui: dt.setup_ai() dt.makeHDF5() dt.process() dt.show_stats() else: from pyFAI.gui import qt from pyFAI.diffmap_widget import DiffMapWidget app = qt.QApplication([]) window = DiffMapWidget() window.set_config(config) # window.restore() window.show() sys.exit(app.exec_())
def integrate_gui(options, args): from pyFAI.gui import qt from pyFAI.integrate_widget import AIWidget app = qt.QApplication([]) if not args: dia = qt.QFileDialog(directory=os.getcwd()) dia.setFileMode(qt.QFileDialog.ExistingFiles) dia.exec_() try: args = [str(i) for i in dia.selectedFiles()] except UnicodeEncodeError as err: logger.error("Problem with the name of some files: %s" % (err)) args = [unicode(i) for i in dia.selectedFiles()] window = AIWidget(args, options.output, options.format, options.slow, options.rapid, options.json) window.set_input_data(args) window.show() return app.exec_()
def main(): app = qt.QApplication([]) widget = CalibrationWindow() setup(widget.model()) widget.setVisible(True) app.exec_()