This file contains 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
import cv2 | |
import imutils | |
import time | |
cap = cv2.VideoCapture(0) | |
ret, frame = cap.read() | |
def takePicture(): | |
(grabbed, frame) = cap.read() | |
showimg = frame |
This file contains 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
# Install a pip package in the current Jupyter kernel | |
import sys | |
!{sys.executable} -m pip install numpy |
This file contains 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
<?php | |
/** | |
* Get all the files and directories recursively. | |
* | |
* @param $dir | |
* @param array $results | |
* | |
* @return array | |
*/ | |
function getDirContents( $dir, &$results = array() ) { |
This file contains 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
<?php | |
/* | |
* @var $installer Mage_Catalog_Model_Resource_Eav_Mysql4_Setup | |
*/ | |
$installer = $this; | |
$installer->startSetup(); | |
$connection = $installer->getConnection(); | |
$connection->beginTransaction(); | |
try { |
This file contains 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
icacls "L:\AAU\Semester 8th\CLAAS DATA\recordings" /grant everyone:f /t |
This file contains 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
import xml.etree.ElementTree as ET | |
import pickle | |
import os | |
from os import listdir, getcwd | |
from os.path import join | |
directory = os.fsencode(dir_in_string) | |
for file in os.listdir(directory): | |
filename = os.fsdecode(file) |
This file contains 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
<?php | |
$weight = Mage::getSingleton('checkout/session') | |
->getQuote() | |
->getShippingAddress() | |
->getWeight(); |
This file contains 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
function validateEmail(email) { | |
var re = /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/; | |
return re.test(email); | |
} |
This file contains 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
import xml.etree.ElementTree as ET | |
import pickle | |
import os | |
from os import listdir, getcwd | |
from os.path import join | |
from PIL import Image | |
source_dir = "C:\\Users\\Lukas\\Desktop\\KITTI dataset\\left_camera\\VOC2012\\JPEGImages" | |
directory = os.fsencode(source_dir) |
This file contains 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
new Ajax.Request("<?= Mage::helper('adminhtml')->getUrl('adminhtml/password/securitycheck') ?>", { | |
method: 'POST', | |
parameters: {'password': password}, | |
requestHeaders: {Accept: 'application/json'}, | |
onSuccess: function(response){ | |
// Parse text as JSON | |
response = JSON.parse(response.responseText); | |
// Redirect | |
window.location.href = deleteURL; | |
} |
OlderNewer