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
from os import listdir | |
from os.path import isfile, join | |
from PIL import Image, ImageOps, ImageChops, ImageFilter | |
import random | |
import glob | |
mypath = "dermnetMini/train/Acne/" | |
imagefiles = glob.glob(mypath + '*.jpg') | |
cnt=0 |
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
model = Sequential([ | |
Conv2D(64, (3,3), activation='relu', input_shape=input_shape), | |
MaxPooling2D((2,2)), | |
Conv2D(32, (3,3), activation='relu'), | |
MaxPooling2D((2,2)), | |
Flatten(), | |
Dense(16, activation='relu'), | |
Dense(10, activation='softmax') | |
]) |
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
# -*- coding: utf-8 -*- | |
import tensorflow as tf | |
assert tf.__version__.startswith('2') | |
tf.random.set_seed(1234) | |
import os | |
import re | |
import numpy as np |
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 singleNumber; | |
import java.util.*; | |
public class SingleNumber { | |
public static void main(String[] args) { | |
int arr[]= {4,5,6,5,6,4,7}; | |
HashMap<Integer, Integer> h = new HashMap<>(); | |
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
# Copyright 2019 Google LLC | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# https://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, |
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
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, |
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
# Copyright 2019 Google LLC | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# https://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, |
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
wget http://storage.googleapis.com/cloud-iot-edge-pretrained-models/edgetpu_api.tar.gz | |
tar xzf edgetpu_api.tar.gz | |
cd python-tflite-source | |
bash ./install.sh | |
Caution: During installation, |
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 anagram; | |
import java.util.Arrays; | |
public class checkForAnagram { | |
public static boolean _checkForAnagram(String first, String second ) { | |
int size1= first.length(), size2=second.length(), count=0; | |
char[] f=new char[size1]; | |
char[] s= new char[size2]; |
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 java.applet.*; | |
import java.awt.*; | |
public class cos extends Applet{ | |
// author @ayyuce | |
// This program draws cos line | |
public void paint(Graphics g){ | |
g.setColor(Color.BLUE); | |
g.drawLine(50, 300, 750, 300); | |
g.drawLine(400, 50, 400, 550); | |
g.drawLine(750, 300, 725, 325); |
NewerOlder