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
gitlab_username: <your-gitlab-username> | |
gitlab_access_token: <your-gitlab-access-token> | |
github_username: <your-github-username> | |
github_access_token: <your-github-access-token> | |
github_repo_owner: <your-github-repo-owner username or organization name> |
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
imagePath = "test.jpg" | |
# Replace this with the path to your image | |
image = Image.open(imagePath).convert("RGB") | |
# resizing the image to be at least 224x224 and then cropping from the center | |
size = (224, 224) | |
# image = ImageOps.fit(image, size, resample=Image.BICUBIC) | |
image = image.resize(size, resample=Image.BICUBIC) |
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 keras.models import load_model # TensorFlow is required for Keras to work | |
from PIL import Image, ImageOps # Install pillow instead of PIL | |
import numpy as np | |
import os | |
import shutil | |
# ---------------------------- | |
# Setup Model | |
# ---------------------------- | |
# Disable scientific notation for clarity |
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
file_uploads = On | |
memory_limit = 256M | |
upload_max_filesize = 1024M | |
post_max_size = 1024M | |
max_execution_time = 300 | |
max_input_time = 1000 |
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
// Install Jimp | |
// npm install jimp --save | |
// Offical site | |
// https://www.npmjs.com/package/jimp | |
// Sample Reference | |
// https://img.ly/blog/how-to-manipulate-an-image-with-jimp-in-react/ | |
import './App.css'; | |
import Jimp from "jimp"; | |
import { useEffect, useState } from "react"; |
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
# version 1 | |
# Base on alpine OS | |
FROM alpine:latest | |
# | |
WORKDIR /user/local/bin | |
# Make simple hello script | |
RUN echo "echo \"Hello Alpine\"" > ./hello.sh | |
RUN chmod u+x *.sh |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Tailwind Demo</title> | |
<link href="https://unpkg.com/tailwindcss@^2/dist/tailwind.min.css" rel="stylesheet"> | |
</head> |
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
function foo() { | |
var a = 2; | |
function bar() { | |
console.log(a); | |
} | |
bar(); | |
} | |
foo() |
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
#include <stdio.h> | |
#include <iostream> | |
#include <memory> | |
#include <vector> | |
struct Tracer { // ken: from book 'C++ Crash course' Page 97 | |
private: | |
const char* const _name; // const xxx const mean cannot alter both address and content | |
public: | |
Tracer(const char *name) |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Responsive Badge</title> | |
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" integrity="sha384-TX8t27EcRE3e/ihU7zmQxVncDAy5uIKz4rEkgIXeMed4M0jlfIDPvg6uqKI2xXr2" crossorigin="anonymous"> | |
<script src="https://code.jquery.com/jquery-3.5.1.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script> | |
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-ho+j7jyWK8fNQe+A12Hb8AhRq26LrZ/JpcUGGOn+Y7RsweNrtN/tE3MoK7ZeZDyx" crossorigin="anonymous"></script> |
NewerOlder