This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Copyright (c) 2021 Francesco Mazzoli <[email protected]> | |
| // | |
| // Permission to use, copy, modify, and distribute this software for any | |
| // purpose with or without fee is hereby granted, provided that the above | |
| // copyright notice and this permission notice appear in all copies. | |
| // | |
| // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | |
| // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | |
| // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | |
| // ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # coding=utf-8 | |
| """ | |
| A simple VTK widget for PyQt or PySide. | |
| See http://www.trolltech.com for Qt documentation, | |
| http://www.riverbankcomputing.co.uk for PyQt, and | |
| http://pyside.github.io for PySide. | |
| This class is based on the vtkGenericRenderWindowInteractor and is | |
| therefore fairly powerful. It should also play nicely with the | |
| vtk3DWidget code. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from pyueye import ueye | |
| import numpy as np | |
| import cv2 | |
| def main(): | |
| # init camera | |
| hcam = ueye.HIDS(0) | |
| ret = ueye.is_InitCamera(hcam, None) | |
| print(f"initCamera returns {ret}") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| """ | |
| A quick, partial implementation of ENet (https://arxiv.org/abs/1606.02147) using PyTorch. | |
| The original Torch ENet implementation can process a 480x360 image in ~12 ms (on a P2 AWS | |
| instance). TensorFlow takes ~35 ms. The PyTorch implementation takes ~25 ms, an improvement | |
| over TensorFlow, but worse than the original Torch. | |
| """ | |
| from __future__ import absolute_import |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cmake_minimum_required(VERSION 2.8.11) | |
| project(VtkFboInQtQuick) | |
| set(CMAKE_INCLUDE_CURRENT_DIR ON) | |
| set(CMAKE_AUTOMOC ON) | |
| find_package(VTK REQUIRED) | |
| include(${VTK_USE_FILE}) |