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
#include <iostream> | |
#include <stack> | |
#include <queue> | |
using namespace std; | |
struct ListNode { | |
int val; | |
ListNode *next; | |
ListNode(int x) : val(x), next(NULL) {} | |
}; |
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 os | |
import subprocess | |
import random | |
def isVideo(f): | |
ext = f.split(".")[-1] | |
if ext == "mp4": | |
return True | |
return False |
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
@echo off | |
for %%x in (*.ARW) do call :for_body %%x >> a7s.txt | |
exit /b | |
:for_body | |
echo %1 | |
dcraw.exe -i -v %1 | findstr /i /B /c:"Camera Multip" | |
exit/b | |
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 os | |
root = "F:\\Camera_Calibration\\A7S2\\16000" | |
for dirPath, _, files in os.walk(root): | |
for f in files: | |
# print (os.path.join(dirPath, f)[-22:]) | |
print (f[9:-4]) | |
try: | |
os.mkdir(os.path.join(root, f[9: -4])) |
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 os | |
import subprocess | |
import random | |
def isVideo(f): | |
ext = f.split(".")[-1] | |
if ext == "mp4": | |
return True | |
return False |
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
def augment(images, labels, | |
resize=None, # (width, height) tuple or None | |
horizontal_flip=False, | |
vertical_flip=False, | |
rotate=0, # Maximum rotation angle in degrees | |
crop_probability=0, # How often we do crops | |
crop_min_percent=0.6, # Minimum linear dimension of a crop | |
crop_max_percent=1., # Maximum linear dimension of a crop | |
mixup=0): # Mixup coeffecient, see https://arxiv.org/abs/1710.09412.pdf | |
if resize is not None: |
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
app.project.bitsPerChannel = 16 | |
myFootage = app.project.importFileWithDialog()[0] | |
footageName = myFootage.file.fsName | |
$.writeln(footageName) | |
var location = "B.M. Playa" | |
//var m = footageName.match(/\d{4}_\d{1,2}_\d{1,2}_.[^\\]*/gi)[0] | |
var n = footageName.match(/\d{1}_\d{2}_\d{4}/gi)[0] | |
$.writeln(location + n) |
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 tensorflow as tf | |
import numpy as np | |
from tqdm import tqdm | |
class RNN(object): | |
def __init__(self, params): | |
self.params = params | |
def rnn_cell(self, x, ht0, hidden_size = 100, reuse = True): |
NewerOlder