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
<html> | |
<head></head> | |
<body> | |
<p id="timer"> | |
</p> | |
<style> | |
#timer{ | |
font-size: 60px; | |
} | |
</style> |
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 glob | |
import numpy as np | |
#goal: when I have a directory structure that looks like this: | |
# -data | |
# -cats(contains all cat images) | |
# -dogs(contains all dog images) | |
# -elephants(contains all elephant images) | |
# |
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
package tspsim; | |
public class Product implements Cloneable{ | |
private int id; | |
private int x; | |
private int y; | |
public Product(int id, int x, int y) { | |
this.id = id; | |
this.x = x; |
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
grayImg = cv2.imread('../my-images/' + row[1], 0) | |
keypoints, descriptors = sift.detectAndCompute(grayImg, None) | |
descriptors = np.insert(descriptors, 0, 128, 1) | |
vectorArray = np.concatenate((vectorArray, descriptors), axis = 0) | |
vectorArray.astype(np.int32).tofile('./my_sift_descriptors.fvecs') | |
#the above code is faulty and should first insert an int32 of with the dimension as value and subsequently float32 values of the vector itself | |
#the following code is correct: |
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 Data.Char | |
iunwords :: [String] -> String | |
iunwords [] = "" | |
iunwords [x] = x | |
iunwords (x:y:ys) = x ++ " " ++ iunwords (y:ys) | |
junwords :: [String] -> String | |
junwords (x:xs) = foldr func "" (x:xs) | |
where |
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
PS C:\Users\gertj\Documents\Xamarin.Forms> ./build.ps1 -Target NugetPack | |
Tool 'cake.tool' (version '1.0.0') was restored. Available commands: dotnet-cake | |
Restore was successful. | |
The assembly 'Cake.Xamarin, Version=3.0.2.0, Culture=neutral, PublicKeyToken=null' | |
is referencing an older version of Cake.Core (0.33.0). | |
For best compatibility it should target Cake.Core version 1.0.0. | |
The assembly 'Cake.Android.Adb, Version=3.2.0.0, Culture=neutral, PublicKeyToken=null' | |
is referencing an older version of Cake.Core (0.33.0). | |
For best compatibility it should target Cake.Core version 1.0.0. |