Skip to content

Instantly share code, notes, and snippets.

View ksdkamesh99's full-sized avatar
💻
Sleep-Code-Eat

Sai Durga Kamesh Kota ksdkamesh99

💻
Sleep-Code-Eat
View GitHub Profile
@ksdkamesh99
ksdkamesh99 / karatsuba.cpp
Last active May 1, 2020 04:47
FAST C/C++ Implementation of the Karatsuba Multiplication algorithm.Fast Multiplication of 2 integers using Karatsuba Algorithm as a part of practice.
#include<bits/stdc++.h>
using namespace std;
typedef long long int lli;
typedef long long ll;
#define fi(i,n) for(int i=0;i<n;i++)
#define Fi(i,k,n) for(int i=k;i<n;i++)
#define fd(i,n) for(int i=n-1;i>=0;i--)
#define Fd(i,k,n) for(int i=n-1;i>=k;i--)
#define pop(i) __builtin_popcount(i)
const int mod = 1000000007;
@ksdkamesh99
ksdkamesh99 / colors.xml
Created May 1, 2020 04:50
Android Colors.It is a collection of almost all colors used in developing any android application.
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="lavender_blush">#FFF0F5</color>
<color name="papaya_whip">#FFEFD5</color>
<color name="blanched_almond">#FFEBCD</color>
<color name="misty_rose">#FFE4E1</color>
<color name="bisque">#FFE4C4</color>
<color name="moccasin">#FFE4B5</color>
<color name="navajo_white">#FFDEAD</color>
<color name="peach_puff">#FFDAB9</color>
@ksdkamesh99
ksdkamesh99 / fibnoci_matrix_exponentiation.cpp
Created May 1, 2020 04:54
Fibnoci Series Using matrix Exponentiation
#include<bits/stdc++.h>
using namespace std;
int** multiply(int** a,int** b){
int** c=new int*[2];
for(int i=0;i<2;i++){
c[i]=new int [2];
for(int j=0;j<2;j++){
@ksdkamesh99
ksdkamesh99 / Seiveoferothenus.cpp
Created May 1, 2020 05:00
Implementation of A classical Way of generating the prime numbers between 1 to n using Seive of Erothenus Algorithm.
#include<bits/stdc++.h>
using namespace std;
typedef long long int lli;
typedef long long ll;
#define fi(i,n) for(int i=0;i<n;i++)
#define Fi(i,k,n) for(int i=k;i<n;i++)
#define fd(i,n) for(int i=n-1;i>=0;i--)
#define Fd(i,k,n) for(int i=n-1;i>=k;i--)
#define pop(i) __builtin_popcount(i)
const int mod = 1000000007;
@ksdkamesh99
ksdkamesh99 / Page Rank Algorithm.py
Created May 9, 2020 18:53
Implementation of pagerank algorithm using python networkx library
# -*- coding: utf-8 -*-
"""Page Rank Algorithm.ipynb
Automatically generated by Colaboratory.
Original file is located at
https://colab.research.google.com/drive/1oUC_418I6e2nv_2xBQ0sgXZtDfA98zuH
"""
cd /content/drive/My Drive/medium blogs/Page Rank Algorithm
from keras.preprocessing.image import ImageDataGenerator
datagen=ImageDataGenerator()
datagen=ImageDataGenerator(
featurewise_center=False,
samplewise_center=False,
featurewise_std_normalization=False,
samplewise_std_normalization=False,
zca_whitening=False,
zca_epsilon=1e-06,
rotation_range=0,
width_shift_range=0.0,
height_shift_range=0.0,
imagegen=datagen.flow(
x,
y=None,
batch_size=32,
shuffle=True,
sample_weight=None,
seed=None,
save_to_dir=None,
save_prefix="",
save_format="png",
imagegen=datagen.flow_from_dataframe(
dataframe,
directory=None,
x_col="filename",
y_col="class",
weight_col=None,
target_size=(256, 256),
color_mode="rgb",
classes=None,
class_mode="categorical",