Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
import pandas as pd | |
import boto3 | |
def group_response(): | |
group = [] | |
client = boto3.client('cognito-idp','us-east-2') | |
response = client.list_groups(UserPoolId="us-east-2_FRhf7xm7F") | |
while(response["NextToken"]!=""): | |
response = client.list_groups(UserPoolId="us-east-2_FRhf7xm7F",NextToken=response['NextToken']) | |
group.append(response['Groups']) |
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
import pandas as pd | |
import boto3 | |
import sys | |
import botocore | |
import botocore.exceptions | |
def group_response(): | |
group = [] | |
client = boto3.client('cognito-idp','us-east-2') | |
response = client.list_groups(UserPoolId="us-east-2_FRhf7xm7F") |
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
import pandas as pd | |
import boto3 | |
import sys | |
import botocore | |
import botocore.exceptions | |
########################################################################################################################## | |
def group_response(): | |
group = [] | |
client = boto3.client('cognito-idp','us-east-2') | |
response = client.list_groups(UserPoolId="us-east-2_FRhf7xm7F") |
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
import pandas as pd | |
import boto3 | |
import sys | |
import botocore | |
import botocore.exceptions | |
########################################################################################################################## | |
def group_response(): | |
group = [] | |
client = boto3.client('cognito-idp','us-east-2') | |
response = client.list_groups(UserPoolId="us-east-2_FRhf7xm7F") |
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
import spacy | |
from spacy import displacy | |
def find_subject_sentence(str): | |
nlp = spacy.load('en_core_web_sm',disable=['ner','textcat']) | |
text = str | |
doc = nlp(text) | |
displacy.render(doc, style='dep',jupyter=True) | |
for token in doc: |
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
import spacy | |
from spacy import displacy | |
def find_subject_sentence(str): | |
nlp = spacy.load('en_core_web_sm',disable=['ner','textcat']) | |
text = str | |
doc = nlp(text) | |
displacy.render(doc, style='dep',jupyter=True) | |
sub = '\0' | |
for token in doc: | |
# extract subject |
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 sklearn.feature_extraction.text import TfidfVectorizer | |
import numpy as np | |
from nltk.corpus import stopwords | |
from nltk.tokenize import word_tokenize | |
def find_keyword_sentence(str): | |
icnt = 0 | |
keyword = '' | |
for element in str: | |
if element == ' ': |
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
import pandas as pd | |
import numpy as np | |
import matplotlib.pyplot as plt | |
from statistics import * | |
class AdvertisementAgency: | |
def __init__(self): | |
self.advertisement_dataset = pd.read_csv("Advertising.csv") | |
self.x_axis_values = self.advertisement_dataset.TV | |
self.y_axis_values = self.advertisement_dataset.sales | |
self.mean_x = mean(self.x_axis_values) |