π§βπ»
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
# Conditions | |
USE_PINCODES = False # FLAG to search by pincode or district | |
VACCINE_CHOICE = ["COVISHIELD", "COVAXIN"] | |
AGE_LIMIT = [18] | |
PINCODES_TO_SEARCH = ["110037"] | |
DISTRICT_CODES_TO_SEARCH = ["140","141","142","143","144","145","146","147","148","149","150"] | |
TIME_INTERVAL = 60 # in seconds | |
ALLOW_DESKTOP_NOTIFICATION = True # Requires additional libraries -> https://pypi.org/project/py-notifier/ | |
DOSE1 = "available_capacity_dose1" | |
DOSE2 = "available_capacity_dose2" |
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
class Node: | |
def __init__ (self, info): | |
self.left = None | |
self.right = None | |
self.info = info | |
def addLeft(self, node): | |
self.left = node | |
def getLeft(self): |
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
class SudokuSolver: | |
# Initializing required variables and validate board | |
def __init__(self, board, boardSize=9, boxSize=3): | |
self.boardSize = boardSize | |
self.boxSize = boxSize | |
self.board = board | |
self.__validateBoard__() | |
# Validate if the board is of the proper format else throw an exception | |
def __validateBoard__(self): |
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
MAX = 999999999 | |
def get_min(a, b, c, index): | |
if a <=b and a <=c: | |
return a, index -1 | |
if b <=a and b <= c: | |
return b, index // 2 | |
if c <= a and c <= b: | |
return c, index // 3 |
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
#!/usr/bin/env python | |
""" | |
author: sidd607@gmail.com | |
version: 0.0.1 | |
Reads the buy details from a csv file (coins.csv) and calculates the wallets profit | |
Uses Koinex API tracker | |
csv format | |
Coin,Date,Quantity,BuyPrice,Cost |
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
https://search-siddtest-xcno5mgnsqidqwrzg2js25i5ge.us-west-2.es.amazonaws.com/_plugin/kibana/#/visualize/ | |
create?type=histogram&indexPattern=plivoredshift&_g=()&_a=( | |
filters:!(), | |
linked:!f, | |
query:( | |
query_string: | |
(analyze_wildcard:!t,query:'*')),vis: | |
(aggs:!((id:'1',params:(),schema:metric,type:count), | |
(id:'3',params:(field:cloud_rate,order:desc,orderBy:'1',size:5), |
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
#-------------------Retrieving and Cleaning Data-------------- | |
data = read.csv("filter.csv",header=T, na.strings=c("")) | |
sapply(data, function(x) sum(is.na(x))) | |
data = subset(data,select=c(2,3,5,6,7,8,10,12)) | |
data$Age[is.na(data$Age)] = mean(data$Age, na.rm = T) | |
#is.factor(data$Sex) | |
#is.factor(data$Embarked) | |
data = data[!is.na(data$Embarked),] | |
rownames(data) = NULL | |
trainData = data[1:800,] |
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
# Load the raw training data and replace missing values with NA | |
training.data.raw <- read.csv('train.csv',header=T,na.strings=c("")) | |
# Output the number of missing values for each column | |
sapply(training.data.raw,function(x) sum(is.na(x))) | |
# Quick check for how many different values for each feature | |
sapply(training.data.raw, function(x) length(unique(x))) | |
# A visual way to check for missing data |
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 <opencv2/imgproc/imgproc.hpp> | |
#include <opencv2/highgui/highgui.hpp> | |
#include <iostream> | |
#include <vector> | |
using namespace std; | |
using namespace cv; | |
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 <opencv2/imgproc/imgproc.hpp> | |
#include <opencv2/highgui/highgui.hpp> | |
#include <iostream> | |
#include <vector> | |
using namespace std; | |
using namespace cv; | |
NewerOlder