I uninstalled arcmap and all existing python installations. Then I followed the instructions from https://www.youtube.com/watch?v=Chq9fTRKsHk&t=2s to install qgis and set the environment variables.
I'm attempting to run the script from the second video (https://www.youtube.com/watch?v=Y8JjvBKOCDk&list=PLzHdTn7Pdxs4AvkJeJwlyav2-at9QwKWR) which should launch a blank canvas.
from qgis.core import *
from qgis.gui import *
from PyQt4.QtCore import *
from PyQt4 import QtGui
app = QtGui.QApplication
QgsApplication.setPrefixPath("C:/OSGeo4W/apps/qgis", True)
QgsApplication.initQgis()
window = QtGui.QMainWindow()
window_frame = QtGui.QFrame(window) 11
window.setCentralWidget(window_frame)
frame_layout = QtGui.QGridLayout(window_frame)
canvas = QgsMapCanvas()
frame_layout.addWidget(canvas)
window.show()
app.exec_()
It's supposed to bring up a canvas but does not.
The error I'm getting is
Process finished with exit code -1073741819 (0xC0000005)
I don't know if the problem is in the environment variables or in the script. Any ideas?