code stringlengths 114 1.05M | path stringlengths 3 312 | quality_prob float64 0.5 0.99 | learning_prob float64 0.2 1 | filename stringlengths 3 168 | kind stringclasses 1
value |
|---|---|---|---|---|---|
from .utils import parse_time, _get_as_snowflake, _bytes_to_base64_data
from .enums import VoiceRegion
from .guild import Guild
__all__ = (
'Template',
)
class _FriendlyHttpAttributeErrorHelper:
__slots__ = ()
def __getattr__(self, attr):
raise AttributeError('PartialTemplateState does not suppor... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/template.py | 0.808105 | 0.205475 | template.py | pypi |
import datetime
from . import utils
from .enums import VoiceRegion, try_enum
from .member import VoiceState
class CallMessage:
"""Represents a group call message from Discord.
This is only received in cases where the message type is equivalent to
:attr:`MessageType.call`.
.. deprecated:: 1.7
At... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/calls.py | 0.858556 | 0.282643 | calls.py | pypi |
from .enums import UserFlags
__all__ = (
'SystemChannelFlags',
'MessageFlags',
'PublicUserFlags',
'Intents',
'MemberCacheFlags',
)
class flag_value:
def __init__(self, func):
self.flag = func(None)
self.__doc__ = func.__doc__
def __get__(self, instance, owner):
if ... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/flags.py | 0.84916 | 0.26499 | flags.py | pypi |
from .asset import Asset
from . import utils
class _EmojiTag:
__slots__ = ()
class PartialEmoji(_EmojiTag):
"""Represents a "partial" emoji.
This model will be given in two scenarios:
- "Raw" data events such as :func:`on_raw_reaction_add`
- Custom emoji that the bot cannot see from e.g. :attr:... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/partial_emoji.py | 0.929011 | 0.312593 | partial_emoji.py | pypi |
from . import utils
from .user import BaseUser
from .asset import Asset
from .enums import TeamMembershipState, try_enum
__all__ = (
'Team',
'TeamMember',
)
class Team:
"""Represents an application team for a bot provided by Discord.
Attributes
-------------
id: :class:`int`
The team ... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/team.py | 0.904027 | 0.257847 | team.py | pypi |
from .flags import BaseFlags, flag_value, fill_with_flags, alias_flag_value
__all__ = (
'Permissions',
'PermissionOverwrite',
)
# A permission alias works like a regular flag but is marked
# So the PermissionOverwrite knows to work with it
class permission_alias(alias_flag_value):
pass
def make_permissio... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/permissions.py | 0.904648 | 0.362066 | permissions.py | pypi |
from . import utils
from .user import User
from .asset import Asset
from .team import Team
class AppInfo:
"""Represents the application info for the bot provided by Discord.
Attributes
-------------
id: :class:`int`
The application ID.
name: :class:`str`
The application name.
... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/appinfo.py | 0.818556 | 0.339307 | appinfo.py | pypi |
from .mixins import Hashable
from .asset import Asset
from .utils import snowflake_time
from .enums import StickerType, try_enum
class Sticker(Hashable):
"""Represents a sticker.
.. versionadded:: 1.6
.. container:: operations
.. describe:: str(x)
Returns the name of the sticker.
... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/sticker.py | 0.925407 | 0.417331 | sticker.py | pypi |
import colorsys
import random
class Colour:
"""Represents a Discord role colour. This class is similar
to a (red, green, blue) :class:`tuple`.
There is an alias for this called Color.
.. container:: operations
.. describe:: x == y
Checks if two colours are equal.
.. de... | /redcord.py-1.7.3.tar.gz/redcord.py-1.7.3/discord/colour.py | 0.951986 | 0.522933 | colour.py | pypi |
import math
import matplotlib.pyplot as plt
from .Generaldistribution import Distribution
class Gaussian(Distribution):
""" Gaussian distribution class for calculating and
visualizing a Gaussian distribution.
Attributes:
mean (float) representing the mean value of the distribution
stdev (float) representing ... | /reddaj_distributions-0.1.tar.gz/reddaj_distributions-0.1/reddaj_distributions/Gaussiandistribution.py | 0.688364 | 0.853058 | Gaussiandistribution.py | pypi |
import datetime
import time
import copy
from .util import print_msg, format_satoshis, print_stderr
from .bitcoin import is_valid, hash_160_to_bc_address, hash_160
from decimal import Decimal
import bitcoin
from .transaction import Transaction
class Command:
def __init__(self, name, min_args, max_args, requires_n... | /reddcoin-electrum-1.0.5.tar.gz/reddcoin-electrum-1.0.5/lib/commands.py | 0.544075 | 0.152631 | commands.py | pypi |
__author__ = 'laudney'
from pprint import pprint
import numpy as np
# Kimoto Gravity Well difficulty retarget algo for Reddcoin
class KGW(object):
def __init__(self):
self.time_day_seconds = 24 * 60 * 60
self.last_pow_block = 260799
# 0x00000FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF... | /reddcoin-electrum-1.0.5.tar.gz/reddcoin-electrum-1.0.5/lib/kgw.py | 0.428233 | 0.296973 | kgw.py | pypi |
__version__ = "0.3"
__about = "bmp module, version %s, written by Paul McGuire, October, 2003, updated by Margus Laak, September, 2009" % __version__
from math import ceil, hypot
def shortToString(i):
hi = (i & 0xff00) >> 8
lo = i & 0x00ff
return chr(lo) + chr(hi)
def longToString(i):
hi = (long(i) & 0x7ff... | /reddcoin-electrum-1.0.5.tar.gz/reddcoin-electrum-1.0.5/lib/bmp.py | 0.614047 | 0.186169 | bmp.py | pypi |
import threading, time, Queue, os, sys, shutil
from .util import user_dir, appdata_dir, print_error
from .bitcoin import *
class TxVerifier(threading.Thread):
""" Simple Payment Verification """
def __init__(self, network, storage):
threading.Thread.__init__(self)
self.daemon = True
... | /reddcoin-electrum-1.0.5.tar.gz/reddcoin-electrum-1.0.5/lib/verifier.py | 0.413596 | 0.161089 | verifier.py | pypi |
# list of words from http://en.wiktionary.org/wiki/Wiktionary:Frequency_lists/Contemporary_poetry
words = [
"like",
"just",
"love",
"know",
"never",
"want",
"time",
"out",
"there",
"make",
"look",
"eye",
"down",
"only",
"think",
"heart",
"back",
"then",
"into",
"about",
"more",
"away",
"still",
"them",
"take",
"thi... | /reddcoin-electrum-1.0.5.tar.gz/reddcoin-electrum-1.0.5/lib/old_mnemonic.py | 0.520253 | 0.439868 | old_mnemonic.py | pypi |
import bitcoin
from .bitcoin import *
from .i18n import _
from .transaction import Transaction, is_extended_pubkey
from .util import print_msg
class Account(object):
def __init__(self, v):
self.receiving_pubkeys = v.get('receiving', [])
self.change_pubkeys = v.get('change', [])
# addresse... | /reddcoin-electrum-1.0.5.tar.gz/reddcoin-electrum-1.0.5/lib/account.py | 0.695441 | 0.233783 | account.py | pypi |
from __future__ import absolute_import
import importlib
import logging
import types
import redbaron
from . import validators
__all__ = ['ProviderBase', 'ChainedProvider']
logger = logging.getLogger(__name__)
class ProviderBase(object):
"""Base class for all Providers.
A provider exposes methods via the ... | /reddel-server-0.2.0.tar.gz/reddel-server-0.2.0/src/reddel_server/provider.py | 0.875654 | 0.252102 | provider.py | pypi |
from __future__ import absolute_import
import abc
import redbaron
import six
from . import redlib
__all__ = ['ValidatorInterface', 'OptionalRegionValidator', 'MandatoryRegionValidator',
'SingleNodeValidator', 'TypeValidator', 'ValidationException']
class ValidationException(Exception):
"""Raised w... | /reddel-server-0.2.0.tar.gz/reddel-server-0.2.0/src/reddel_server/validators.py | 0.935317 | 0.485539 | validators.py | pypi |
import logging
import epc.handler
import epc.server
import six
__all__ = ['Server']
logger = logging.getLogger(__name__)
class Server(epc.server.EPCServer):
"""EPCServer that provides basic functionality.
This is a simple :class:`epc.server.EPCServer` that exposes methods for clients to call remotely.
... | /reddel-server-0.2.0.tar.gz/reddel-server-0.2.0/src/reddel_server/server.py | 0.812235 | 0.200108 | server.py | pypi |
# Automatic Reddit Account Maker

A python script on selenium to automatically create Reddit accounts.
## Table of Contents
- [Introducing](#introducing)
- [Features](#features)
- [Quick info](#quick-info)
- [TODO](#todo)
- [Gettin... | /reddit-account-generator-1.2.0.tar.gz/reddit-account-generator-1.2.0/README.md | 0.540924 | 0.887838 | README.md | pypi |
import time
from datetime import datetime
from datetime import timedelta
from warnings import warn
import six
from cqlmapper import ConnectionInterface
from cqlmapper import CQLEngineException
from cqlmapper import TIMEOUT_NOT_SET
from cqlmapper.query import DMLQuery
from cqlmapper.statements import BaseCQLStatement... | /reddit_cqlmapper-0.3.0-py3-none-any.whl/cqlmapper/batch.py | 0.787319 | 0.210848 | batch.py | pypi |
import re
import six
from cassandra.util import OrderedDict
from cqlmapper import columns
from cqlmapper import CQLEngineException
from cqlmapper import models
class UserTypeException(CQLEngineException):
pass
class UserTypeDefinitionException(UserTypeException):
pass
class BaseUserType(object):
""... | /reddit_cqlmapper-0.3.0-py3-none-any.whl/cqlmapper/usertype.py | 0.623148 | 0.224034 | usertype.py | pypi |
import logging
from copy import copy
from copy import deepcopy
from datetime import date
from datetime import datetime
from datetime import timedelta
from uuid import UUID as _UUID
import six
from cassandra import util
from cassandra.cqltypes import _cqltypes
from cassandra.cqltypes import SimpleDateType
from cassan... | /reddit_cqlmapper-0.3.0-py3-none-any.whl/cqlmapper/columns.py | 0.661486 | 0.182972 | columns.py | pypi |
import sys
from datetime import datetime
from cqlmapper import UnicodeMixin
from cqlmapper import ValidationError
if sys.version_info >= (2, 7):
def get_total_seconds(td):
return td.total_seconds()
else:
def get_total_seconds(td):
# integer division used here to emulate built-in total_sec... | /reddit_cqlmapper-0.3.0-py3-none-any.whl/cqlmapper/functions.py | 0.480235 | 0.301915 | functions.py | pypi |
import logging
import re
from warnings import warn
import six
from cassandra.concurrent import execute_concurrent_with_args
from cassandra.metadata import protect_name
from cassandra.util import OrderedDict
from cqlmapper import columns
from cqlmapper import CQLEngineException
from cqlmapper import query
from cqlma... | /reddit_cqlmapper-0.3.0-py3-none-any.whl/cqlmapper/models.py | 0.66628 | 0.182845 | models.py | pypi |
import pandas as pd
from .exceptions import ColumnNameError
def to_pandas(subreddit_data, separate=False):
"""Convert raw post or comment data collected to a pandas `DataFrame`.
Parameters
----------
subreddit_data : dict
Raw post or comment data collected with the `DataCollector.get_data`
... | /reddit-data-collector-1.1.0.tar.gz/reddit-data-collector-1.1.0/src/reddit_data_collector/io.py | 0.854004 | 0.694005 | io.py | pypi |
import logging
from typing import Any
from typing import Callable
from typing import Dict
from typing import ItemsView
from typing import Iterator
from typing import KeysView
from typing import List
from typing import Mapping
from typing import Optional
from typing import Union
from typing import ValuesView
from .pro... | /reddit_decider-1.4.2-cp37-abi3-manylinux_2_28_x86_64.whl/rust_decider/__init__.py | 0.90784 | 0.184694 | __init__.py | pypi |
import praw
from neo4j import BoltDriver
from typing import List, Union
from itertools import chain
from reddit_detective.relationships import Submissions, Comments, CommentsReplies
from reddit_detective.karma import (_remove_karma, _set_karma_subreddits, _set_karma_submissions,
_se... | /reddit_detective-0.1.4-py3-none-any.whl/reddit_detective/network.py | 0.730194 | 0.176956 | network.py | pypi |
import praw
from prawcore.exceptions import Redirect, NotFound
from abc import ABC
from reddit_detective.utils import strip_punc
"""
Node types:
Redditor
Employee
Suspended
Submission
Archived
Stickied
Locked
Over18
Subreddit
Over18
Comment
... | /reddit_detective-0.1.4-py3-none-any.whl/reddit_detective/data_models.py | 0.686685 | 0.322553 | data_models.py | pypi |
from neo4j import BoltDriver
from reddit_detective.analytics.utils import (get_redditors, get_user_comments_times,
get_submission_comments_times, get_subreddit_comments_times)
def interaction_score(driver: BoltDriver, username):
"""
For a user in the Graph, shows
# comments received / # comments ... | /reddit_detective-0.1.4-py3-none-any.whl/reddit_detective/analytics/metrics.py | 0.566978 | 0.265015 | metrics.py | pypi |
from __future__ import annotations
import logging
import re
from typing import Any
from typing import Dict
from typing import List
from typing import NamedTuple
from typing import Optional
from typing import Set
import jwt
from baseplate import RequestContext
from baseplate.lib import cached_property
from baseplate... | /reddit_edgecontext-1.6.3.tar.gz/reddit_edgecontext-1.6.3/reddit_edgecontext/__init__.py | 0.937476 | 0.157105 | __init__.py | pypi |
from pyspark.sql import SparkSession
from includes.vars import *
from datetime import date
from includes.functions import loadConfigs
from pyspark.sql.functions import lit
from pyspark.sql.functions import explode
def transform_author_flair():
spark = SparkSession.builder \
.config("spark.hadoop.fs.s3a.aws... | /reddit_etl_abd-0.0.6-py3-none-any.whl/reddit_etl_abd/transform/transform_author_flair.py | 0.465145 | 0.233695 | transform_author_flair.py | pypi |
import hashlib
import logging
import time
from typing import Any
from typing import Dict
from typing import List
from typing import Optional
from typing import Type
from reddit_experiments.providers.base import Experiment
from reddit_experiments.targeting.base import Targeting
from reddit_experiments.targeting.tree_t... | /reddit_experiments-1.8.0b1-py3-none-any.whl/reddit_experiments/providers/simple_experiment.py | 0.893774 | 0.378603 | simple_experiment.py | pypi |
from typing import Any
from typing import Dict
from reddit_experiments.providers.r2 import R2Experiment
class FeatureFlag(R2Experiment):
"""An experiment with a single variant "active".
.. deprecated:: 0.27
Use SimpleExperiment with RolloutVariantSet instead.
Does not log bucketing events to the... | /reddit_experiments-1.8.0b1-py3-none-any.whl/reddit_experiments/providers/feature_flag.py | 0.925386 | 0.698003 | feature_flag.py | pypi |
from typing import Any
from typing import Dict
from typing import List
from typing import Optional
from reddit_experiments.variant_sets.base import VariantSet
class MultiVariantSet(VariantSet):
"""Variant Set designed to handle more than two total treatments.
MultiVariantSets are not designed to support cha... | /reddit_experiments-1.8.0b1-py3-none-any.whl/reddit_experiments/variant_sets/multi_variant_set.py | 0.938414 | 0.576065 | multi_variant_set.py | pypi |
from typing import Any
from typing import Dict
from typing import List
from typing import Optional
from reddit_experiments.variant_sets.base import VariantSet
class SingleVariantSet(VariantSet):
"""Variant Set designed to handle two total treatments.
This VariantSet allows adjusting the sizes of variants wi... | /reddit_experiments-1.8.0b1-py3-none-any.whl/reddit_experiments/variant_sets/single_variant_set.py | 0.936365 | 0.624952 | single_variant_set.py | pypi |
from typing import Any
from typing import Dict
from typing import List
from typing import Optional
from reddit_experiments.variant_sets.base import VariantSet
class RolloutVariantSet(VariantSet):
"""VariantSet designed for feature rollouts. Takes a single variant.
Changing the size of the variant will minim... | /reddit_experiments-1.8.0b1-py3-none-any.whl/reddit_experiments/variant_sets/rollout_variant_set.py | 0.940285 | 0.654936 | rollout_variant_set.py | pypi |
from typing import Any
from typing import Dict
from typing import List
from typing import Optional
from reddit_experiments.variant_sets.base import VariantSet
class RangeVariantSet(VariantSet):
"""Variant Set designed to take fixed bucket ranges.
This VariantSet allows manually setting bucketing ranges.
... | /reddit_experiments-1.8.0b1-py3-none-any.whl/reddit_experiments/variant_sets/range_variant_set.py | 0.933332 | 0.611237 | range_variant_set.py | pypi |
import logging
import operator
from typing import Any
from typing import Callable
from typing import Dict
from typing import List
from typing import Type
from reddit_experiments.targeting.base import Targeting
logger = logging.getLogger(__name__)
class TargetingNodeError(Exception):
pass
class UnknownTarget... | /reddit_experiments-1.8.0b1-py3-none-any.whl/reddit_experiments/targeting/tree_targeting.py | 0.882984 | 0.534612 | tree_targeting.py | pypi |
import functools
from pathlib import Path
from string import Formatter
from typing import (
Iterator,
List,
Optional,
Set,
)
import fire
import toml
from praw.models import (
Submission,
Subreddit,
)
from .types import (
CallMap,
PrawQuery,
SortingOption,
TimeFilterOption,
)
... | /reddit_get-1.1.0-py3-none-any.whl/reddit_get/utils.py | 0.566378 | 0.150372 | utils.py | pypi |
import sys
from typing import (
Dict,
List,
Union,
)
import fire
import praw
from praw.exceptions import MissingRequiredAttributeException
from .types import (
SortingOption,
TimeFilterOption,
)
from .utils import (
create_post_output,
get_post_sorting_option,
get_reddit_query_function... | /reddit_get-1.1.0-py3-none-any.whl/reddit_get/cli.py | 0.585694 | 0.178777 | cli.py | pypi |
import asyncio
import click
from asyncpraw import Reddit # type: ignore
from asyncpraw.reddit import Submission # type: ignore
from tqdm import tqdm
from click import Context, Choice
from typing import Callable, Optional, Tuple
from dataclasses import dataclass
from . import get_reddit, get_media, download_async
@d... | /reddit_media-0.0.3-py3-none-any.whl/redditmedia/cli.py | 0.609175 | 0.16248 | cli.py | pypi |
from __future__ import annotations
import praw
import pandas as pd
import numpy as np
from datetime import datetime
from typing import List
import bcrypt
import os
from nltk.sentiment.vader import SentimentIntensityAnalyzer as SIA
from pprint import pprint
class Crawler(object):
def __init__(
self,
... | /reddit_multimodal_crawler-1.3.2.tar.gz/reddit_multimodal_crawler-1.3.2/reddit_multimodal_crawler/crawler.py | 0.782288 | 0.209146 | crawler.py | pypi |
import os
import csv
import json
import logging
import argparse
from datetime import datetime
import requests
from glyphoji import glyph
from rich import print
from rich.tree import Tree
from rich.markdown import Markdown
from rich.logging import RichHandler
def convert_timestamp_to_datetime(timestamp: int) -> str:... | /reddit_post_scraping_tool-1.9.1.0-py3-none-any.whl/rpst/utils.py | 0.726911 | 0.224969 | utils.py | pypi |
import argparse
from datetime import datetime
import requests
from glyphoji import glyph
from rich import print
from rich.tree import Tree
from .utils import convert_timestamp_to_datetime, write_post_data
def create_post_branch(post: dict, keyword: str, tree: Tree, args: argparse) -> Tree:
"""
This function... | /reddit_post_scraping_tool-1.9.1.0-py3-none-any.whl/rpst/rpst.py | 0.680029 | 0.273458 | rpst.py | pypi |
import praw
from reddit_radio import config, youtube
from reddit_radio.helpers import SingletonMeta, fromtimestamp, safe_parse
from reddit_radio.logging import logger
class Client(metaclass=SingletonMeta):
def __init__(self):
self._reddit = praw.Reddit(**config.REDDIT_CONFIG)
@staticmethod
def s... | /reddit_radio-0.0.2-py3-none-any.whl/reddit_radio/reddit.py | 0.422386 | 0.152916 | reddit.py | pypi |
__author__ = "Fufu Fang"
__copyright__ = "The GNU General Public License v3.0"
if __package__ is None or __package__ == '':
# noinspection PyUnresolvedReferences
from redditDownloader import SubmissionGenerator, CommentGenerator
else:
from .redditDownloader import SubmissionGenerator, CommentGenerator
fro... | /reddit_regex_counter-0.0.2-py3-none-any.whl/reddit_regex_counter/redditRegexCounter.py | 0.808067 | 0.173743 | redditRegexCounter.py | pypi |
import logging
import re
from reddit_sentiment.api.scraper import Scraper
from reddit_sentiment.api.reddit import Reddit
from nltk.sentiment.vader import SentimentIntensityAnalyzer
happy_sentiment = "😁"
sad_sentiment = "😕"
neutral_sentiment = "😐"
class Sentiment():
"""Performs the sentiment analysis on a g... | /reddit-sentiment-1.0.tar.gz/reddit-sentiment-1.0/reddit_sentiment/sentiment.py | 0.580352 | 0.282402 | sentiment.py | pypi |
import logging
from types import BuiltinMethodType
import os
import praw
from reddit_sentiment.api import api
class Reddit(api.API):
"""The Reddit Class obtains data to perform sentiment analysis on
using the Reddit API.
It allows an unauthenticated user to obtain data to analyze various
reddit obj... | /reddit-sentiment-1.0.tar.gz/reddit-sentiment-1.0/reddit_sentiment/api/reddit.py | 0.468304 | 0.218315 | reddit.py | pypi |
import logging
from types import BuiltinMethodType
import requests
from reddit_sentiment.api import api
class Scraper(api.API):
"""The Reddit Class obtains data to perform sentiment analysis by
scraping the Reddit json endpoint.
It allows an unauthenticated user to obtain data to analyze various
red... | /reddit-sentiment-1.0.tar.gz/reddit-sentiment-1.0/reddit_sentiment/api/scraper.py | 0.42322 | 0.330741 | scraper.py | pypi |
import pandas as pd
import praw
from nltk.sentiment.vader import SentimentIntensityAnalyzer
import spacy
from typing import List, Dict
from loguru import logger
# Load English tokenizer, tagger, parser, NER and word vectors
try:
nlp = spacy.load('en_core_web_trf')
except IOError:
logger.warning("Downloading l... | /reddit_stock_sentiment-0.1.3.tar.gz/reddit_stock_sentiment-0.1.3/reddit_stock_sentiment/reddit_stock_sentiment.py | 0.784979 | 0.173708 | reddit_stock_sentiment.py | pypi |
import logging
import sqlite3
import time
import typing
from datetime import date, timedelta
from functools import partial
from itertools import takewhile
from pathlib import Path
from typing import Optional
import praw
import sqlite_utils
import typer
from .reddit_instance import get_auth, reddit_instance
LIMIT = 1... | /reddit_to_sqlite-0.1.0-py3-none-any.whl/reddit_to_sqlite/main.py | 0.630685 | 0.153994 | main.py | pypi |
# reddit-user-to-sqlite
Stores all the content from a specific user in a SQLite database. This includes their comments and their posts.
## Install
The PyPI package is `reddit-user-to-sqlite` ([PyPI Link](https://pypi.org/project/reddit-user-to-sqlite/)). Install it globally using [pipx](https://pypa.github.io/pipx/)... | /reddit_user_to_sqlite-0.4.2.tar.gz/reddit_user_to_sqlite-0.4.2/README.md | 0.456652 | 0.891858 | README.md | pypi |
from typing import Callable, Iterable, Optional, Sequence, TypedDict, TypeVar
from sqlite_utils import Database
from reddit_user_to_sqlite.csv_helpers import PrefixType, build_table_name
from reddit_user_to_sqlite.reddit_api import (
Comment,
Post,
SubredditFragment,
UserFragment,
)
class SubredditR... | /reddit_user_to_sqlite-0.4.2.tar.gz/reddit_user_to_sqlite-0.4.2/reddit_user_to_sqlite/sqlite_helpers.py | 0.581184 | 0.261599 | sqlite_helpers.py | pypi |
import requests
import bs4
import re
class RedditSessionError(Exception):
pass
class RedditSession:
"""
a class used for managing a session with reddit.com
note: it is mostly useful since it takes care of the cookies and the csrf token for you
note: the cookies are handled as a dict and the 'coo... | /reddit_usernames-0.1-py3-none-any.whl/reddit_usernames/reddit_session.py | 0.431584 | 0.253405 | reddit_session.py | pypi |
import HTMLParser, markdown2
class entryData(object):
title = None
author = None
content = None
ID = None
HTML = None
'''Constructor initializes object with only five-digit post ID, in case I want to add something to the mechanism.'''
def __init__(self, ID):
self.ID = ID
'''Se... | /reddit2Kindle-0.5.1.tar.gz/reddit2Kindle-0.5.1/redditKindleLib/utils.py | 0.409457 | 0.270616 | utils.py | pypi |
# Reddit NLP Package [](https://travis-ci.org/jaijuneja/reddit-nlp)
A lightweight Python module that performs tokenization and processing of text on Reddit. It allows you to analyze users, titles, comments and subreddits to understand their v... | /redditnlp-0.1.3.tar.gz/redditnlp-0.1.3/README.md | 0.621771 | 0.915809 | README.md | pypi |
# redditquery
An offline information retrieval system for full-text search on reddit comments.
## Getting Started
Once redditquery is set-up on your system (see Installation and Prerequisites), you can call the package from the command line like so (see Parameters):
```shell
user@host:~ redditquery mode [-h] [-s [... | /redditquery-0.1.1.tar.gz/redditquery-0.1.1/README.md | 0.552057 | 0.927495 | README.md | pypi |
from redditquotebot.utilities import RecordLoader, RecordKeeper, RecordStorer
from redditquotebot.backtesting import combine_records
from typing import List
import argparse
import sys
import os
usage = """
Example 1: Combine comments from multiple records into a single file, discarding duplicates.
rqb_record_comb... | /redditquotebot-0.4.0.tar.gz/redditquotebot-0.4.0/bin/rqb_record_combine.py | 0.642657 | 0.488405 | rqb_record_combine.py | pypi |
from .Additional import Additional
from .Antifraud import Antifraud
from .Authorization import Authorization
from .Cart import Cart
from .Environment import Environment
from .RedeSerializable import RedeSerializable
from .ThreeDSecure import ThreeDSecure
from .Url import Url
from .Refund import Refund
from .Capture imp... | /rede%20payments-1.0.0.tar.gz/rede payments-1.0.0/erede/Transaction.py | 0.61682 | 0.158369 | Transaction.py | pypi |
from .service import *
class eRede:
USER_AGENT = "eRede/1.0 (SDK; Python)"
def __init__(self, store):
"""
:type store: `erede.Store.Store`
"""
self.store = store
def authorize(self, transaction):
return self.create(transaction)
def create(self, transaction):... | /rede%20payments-1.0.0.tar.gz/rede payments-1.0.0/erede/eRede.py | 0.777215 | 0.432782 | eRede.py | pypi |
from .base_actor import BaseActor
from .qagpt import QAGPT
from ..api_pmc_requests import PMCRequester
class KnowledgeBaseSearcher(BaseActor):
_defaults = {
"ip": "83.220.174.161",
"port": "9202",
"prompt": f"Напиши названия 10 статей PubMed Central, в которых подтверждаются следующие... | /redemption-ai-0.0.0.tar.gz/redemption-ai-0.0.0/RAI/actors/knowledge_base_searcher.py | 0.575349 | 0.206374 | knowledge_base_searcher.py | pypi |
from typing import Union
from collections import deque
import tiktoken
from .base_actor import BaseActor
from ..chat import Message
class TokenCounter(BaseActor):
_tokens_per_message = 3
_models = [
"gpt-3.5-turbo",
"gpt-3.5-turbo-16k",
"gpt-4",
"gpt-4-32k",
]
d... | /redemption-ai-0.0.0.tar.gz/redemption-ai-0.0.0/RAI/actors/token_counter.py | 0.816004 | 0.191365 | token_counter.py | pypi |
import json
class Poll:
_bot = "[RBot]"
def __init__(self, json_path: str) -> None:
self.poll = None
self.load(json_path)
self.user_answers = {}
self.joiner = '\n\t'
self.instructions = f"""
<INSTRUCTIONS>
Write a conclusion about my c... | /redemption-ai-0.0.0.tar.gz/redemption-ai-0.0.0/RAI/heuristics/poll.py | 0.432543 | 0.187374 | poll.py | pypi |
from .pmc_models import ModelPMC, ModelPubMedLine
import orjson
import requests
from requests.utils import quote
from pydantic import parse_obj_as
class Singleton(type):
_instances = {}
def __call__(cls, *args, **kwargs):
if cls not in cls._instances:
instance = super().__call__(*args, **kwargs)
... | /redemption-ai-0.0.0.tar.gz/redemption-ai-0.0.0/RAI/api_pmc_requests/api_requester.py | 0.686055 | 0.286553 | api_requester.py | pypi |
from pydantic import BaseModel
from pydantic import parse_obj_as
# Python >= 3.9 version required
#PMC
class ModelPMC(BaseModel):
"""
Serializable model of /index of OpenSearch
"""
class JournalModel(BaseModel):
nlm: str = ''
longname: str = ''
ISSNP: str = ''
ISSNE: str... | /redemption-ai-0.0.0.tar.gz/redemption-ai-0.0.0/RAI/api_pmc_requests/pmc_models.py | 0.641535 | 0.151906 | pmc_models.py | pypi |
# <span style="color:red">Red</span> Engine
> Advanced scheduling system.
-----------------
[](https://pypi.org/project/redengine/)
[](https://github.com/Miksus/red-eng... | /redengine-1.2.0.tar.gz/redengine-1.2.0/README.md | 0.504639 | 0.930205 | README.md | pypi |
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
import numpy as np
import matplotlib.patches as patches
def plot_regresion_lineal_univariada(w,b,x,y,x_label,y_label,title=""):
# genero una ventana de dibujo con una sola zona de dibujo (1,1)
f,ax_data=plt.subplots(1,1)
# dibujo el ... | /redes_neuronales_util-0.3.3-py3-none-any.whl/rnutil/plot.py | 0.532668 | 0.70716 | plot.py | pypi |
from __future__ import division
import math
from collections import namedtuple
DMS = namedtuple('DMS', 'degrees minutes seconds')
def merge_two_dicts(x, y):
""" Given two dicts, merge them into a new dict as a shallow copy."""
z = x.copy()
z.update(y)
return z
def decdeg2dms(dd):
""" Converts... | /redfearn-1.0.4.tar.gz/redfearn-1.0.4/redfearn.py | 0.892123 | 0.727431 | redfearn.py | pypi |
from aenum import Enum, auto
SSDP_ALL = 'ssdp:all'
SSDP_REDFISH = 'urn:dmtf-org:service:redfish-rest:1'
class NoValue(Enum):
def __repr__(self):
return '<%s.%s>' % (self.__class__.__name__, self.name)
class Result(NoValue):
PASS = 'PASS'
FAIL = 'FAIL'
WARN = 'WARN'
NOT_TESTED = 'NOT-T... | /redfish_protocol_validator-1.1.8-py3-none-any.whl/redfish_protocol_validator/constants.py | 0.651133 | 0.156652 | constants.py | pypi |
import re
import xml.etree.ElementTree as ET
from urllib.parse import urlparse
import requests
from redfish_protocol_validator import utils
from redfish_protocol_validator.constants import Assertion, ResourceType, RequestType, Result
from redfish_protocol_validator.system_under_test import SystemUnderTest
safe_char... | /redfish_protocol_validator-1.1.8-py3-none-any.whl/redfish_protocol_validator/protocol_details.py | 0.631481 | 0.226431 | protocol_details.py | pypi |
import logging
from urllib.parse import urlparse
import requests
from redfish_protocol_validator import utils
from redfish_protocol_validator.constants import Assertion, RequestType, Result
from redfish_protocol_validator.system_under_test import SystemUnderTest
def test_header(sut: SystemUnderTest, header, header... | /redfish_protocol_validator-1.1.8-py3-none-any.whl/redfish_protocol_validator/service_requests.py | 0.580828 | 0.177775 | service_requests.py | pypi |
import configparser
import os
import threading
import tkinter as tk
from tkinter import filedialog as tkFileDialog
import traceback
import webbrowser
import redfish_service_validator.RedfishLogo as logo
import redfish_service_validator.RedfishServiceValidator as rsv
g_config_file_name = "config/config.ini"
g_config_... | /redfish_service_validator-2.3.4-py3-none-any.whl/redfish_service_validator/RedfishServiceValidatorGui.py | 0.538741 | 0.182389 | RedfishServiceValidatorGui.py | pypi |
# Redfish Tacklebox
Copyright 2019-2022 DMTF. All rights reserved.
## About
Redfish Tacklebox contains a set of Python3 utilities to perform common management operations with a Redfish service.
The utilities can be used as part of larger management applications, or be used as standalone command line tools.
## Insta... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/README.md | 0.493653 | 0.824815 | README.md | pypi |
from .messages import verify_response
class RedfishEventServiceNotFoundError( Exception ):
"""
Raised when the event service cannot be found
"""
pass
class RedfishEventSubscriptionNotFoundError( Exception ):
"""
Raised when the specified event subscription cannot be found
"""
pass
def... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/event_service.py | 0.708011 | 0.187003 | event_service.py | pypi |
from .messages import verify_response
class RedfishAccountCollectionNotFoundError( Exception ):
"""
Raised when the Account Service or Account Collection cannot be found
"""
pass
class RedfishAccountNotFoundError( Exception ):
"""
Raised when the Account Service or Account Collection cannot be... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/accounts.py | 0.838746 | 0.161585 | accounts.py | pypi |
import warnings
import sys
from .collections import get_collection_ids
from .messages import verify_response
from .resets import reset_types
from . import config
class RedfishSystemNotFoundError( Exception ):
"""
Raised when a matching system cannot be found
"""
pass
class RedfishSystemResetNotFoundEr... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/systems.py | 0.562898 | 0.265425 | systems.py | pypi |
import os
from .messages import verify_response
class RedfishCertificateServiceNotFoundError( Exception ):
"""
Raised when the certificate service cannot be found
"""
pass
class RedfishCertificateLocationsNotFoundError( Exception ):
"""
Raised when the certificate locations cannot be found
... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/certificates.py | 0.810404 | 0.291435 | certificates.py | pypi |
import base64
import os
from .collections import get_collection_ids
from .messages import verify_response
class RedfishLicenseServiceNotFoundError( Exception ):
"""
Raised when the license service cannot be found
"""
pass
class RedfishLicenseCollectionNotFoundError( Exception ):
"""
Raised whe... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/licenses.py | 0.619817 | 0.169045 | licenses.py | pypi |
import shutil
from .messages import verify_response
from enum import Enum
class RedfishLogServiceNotFoundError( Exception ):
"""
Raised when a matching log service cannot be found
"""
pass
class RedfishClearLogNotFoundError( Exception ):
"""
Raised when a log service does not contain the clea... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/logs.py | 0.741861 | 0.28508 | logs.py | pypi |
import warnings
import xlsxwriter
from .collections import get_collection_ids
from .messages import verify_response
from . import config
class RedfishChassisNotFoundError( Exception ):
"""
Raised when a matching chassis cannot be found
"""
pass
def get_system_inventory( context ):
"""
Walks a ... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/inventory.py | 0.637482 | 0.206654 | inventory.py | pypi |
import json
import os
import errno
import math
from .messages import verify_response
class RedfishUpdateServiceNotFoundError( Exception ):
"""
Raised when the update service or an update action cannot be found
"""
pass
def get_simple_update_info( context ):
"""
Locates the SimpleUpdate action ... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/update.py | 0.665737 | 0.211112 | update.py | pypi |
def get_sensors( context , use_id = False ):
"""
Walks a Redfish service for sensor information
Args:
context: The Redfish client object with an open session
use_id: Indicates whether to construct names from 'Id' property values
Returns:
A list containing all sensor readings
... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/sensors.py | 0.756178 | 0.284604 | sensors.py | pypi |
import sys
from .collections import get_collection_ids
from .messages import verify_response
from .resets import reset_types
from .resets import reset_to_defaults_types
class RedfishManagerNotFoundError( Exception ):
"""
Raised when a matching manager cannot be found
"""
pass
class RedfishManagerEthIn... | /redfish_utilities-3.1.9.tar.gz/redfish_utilities-3.1.9/redfish_utilities/managers.py | 0.653348 | 0.296285 | managers.py | pypi |
Copyright 2016-2018 DMTF. All rights reserved.
# redfishtool
## About
***redfishtool*** is a commandline tool that implements the client side of the Redfish RESTful API for Data Center Hardware Management.
**Redfish** is the new RESTful API for hardware management defined by the DMTF Scalable Platform Management Fo... | /redfishtool-1.1.8.tar.gz/redfishtool-1.1.8/README.md | 0.809728 | 0.836521 | README.md | pypi |
<div align="center">
<img alt="redframes" src="images/redframes.png" height="200px">
<br/>
<div align="center">
<a href="https://pandas.pydata.org/"><img alt="Pandas Version" src="https://img.shields.io/badge/pandas-≥1.5,<3.0-blue"></a>
<a href="https://pypi.python.org/pypi/redframes"><img alt="PyPI" s... | /redframes-1.4.1.tar.gz/redframes-1.4.1/README.md | 0.572125 | 0.957278 | README.md | pypi |
class OpenApiException(Exception):
"""The base exception class for all OpenAPIExceptions"""
class ApiTypeError(OpenApiException, TypeError):
def __init__(self, msg, path_to_item=None, valid_classes=None,
key_type=None):
""" Raises an exception for TypeErrors
Args:
... | /redguy-api-1.0.0.tar.gz/redguy-api-1.0.0/openapi_client/exceptions.py | 0.769514 | 0.279315 | exceptions.py | pypi |
import re # noqa: F401
import sys # noqa: F401
import nulltype # noqa: F401
from openapi_client.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
... | /redguy-api-1.0.0.tar.gz/redguy-api-1.0.0/openapi_client/model/inline_response200.py | 0.533397 | 0.156749 | inline_response200.py | pypi |
import re # noqa: F401
import sys # noqa: F401
import nulltype # noqa: F401
from openapi_client.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
... | /redguy-api-1.0.0.tar.gz/redguy-api-1.0.0/openapi_client/model/inline_response2003.py | 0.533397 | 0.169681 | inline_response2003.py | pypi |
import re # noqa: F401
import sys # noqa: F401
import nulltype # noqa: F401
from openapi_client.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
... | /redguy-api-1.0.0.tar.gz/redguy-api-1.0.0/openapi_client/model/inline_response2001.py | 0.533641 | 0.171096 | inline_response2001.py | pypi |
import re # noqa: F401
import sys # noqa: F401
import nulltype # noqa: F401
from openapi_client.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
... | /redguy-api-1.0.0.tar.gz/redguy-api-1.0.0/openapi_client/model/inline_response2002.py | 0.533397 | 0.162247 | inline_response2002.py | pypi |
import re # noqa: F401
import sys # noqa: F401
import nulltype # noqa: F401
from openapi_client.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
... | /redguy-api-1.0.0.tar.gz/redguy-api-1.0.0/openapi_client/model/inline_response200_response_value.py | 0.543833 | 0.166743 | inline_response200_response_value.py | pypi |
import re # noqa: F401
import sys # noqa: F401
import nulltype # noqa: F401
from openapi_client.model_utils import ( # noqa: F401
ApiTypeError,
ModelComposed,
ModelNormal,
ModelSimple,
cached_property,
change_keys_js_to_python,
convert_js_args_to_python_args,
date,
datetime,
... | /redguy-api-1.0.0.tar.gz/redguy-api-1.0.0/openapi_client/model/inline_object2.py | 0.53048 | 0.174551 | inline_object2.py | pypi |
=======
Redhawk
=======
Redhawk is a code navigation system built on the idea of a language agnostic
parse tree. It currently supports C & Python.
Code navigation systems are few and far. They are either too tied to a
language, or are very heuristic in nature --- using regex based parsers.
Redhawk attempts to acheive... | /redhawk-1.2.3.tar.gz/redhawk-1.2.3/README.rst | 0.836755 | 0.652034 | README.rst | pypi |
Mapping Clinical Components to LOINC Codes
==========================================
This document explains how to lookup `LOINC <http://loinc.org>`__ Codes
and map them to a site's local clinical components for RED-I to use.
Lookup LOINC Codes
------------------
1. Download the `LOINC Table File <http://loinc.org/... | /redi-0.15.5.tar.gz/redi-0.15.5/docs/mapping_clinical_components_to_loinc_codes.rst | 0.928918 | 0.715871 | mapping_clinical_components_to_loinc_codes.rst | pypi |
yum Cookbook
============
Configures various YUM components on Red Hat-like systems. Includes LWRP for managing repositories and their GPG keys.
Based on the work done by Eric Wolfe and Charles Duffy on the [yumrepo](https://github.com/atomic-penguin/cookbook-yumrepo) cookbook.
Requirements
------------
Red Hat Ent... | /redi-0.15.5.tar.gz/redi-0.15.5/vagrant/cookbooks/yum/README.md | 0.839537 | 0.743471 | README.md | pypi |
Description
===========
This cookbook provides a complete Debian/Ubuntu style Apache HTTPD
configuration. Non-Debian based distributions such as Red Hat/CentOS,
ArchLinux and others supported by this cookbook will have a
configuration that mimics Debian/Ubuntu style as it is easier to
manage with Chef.
Debian-style A... | /redi-0.15.5.tar.gz/redi-0.15.5/vagrant/cookbooks/apache2/README.md | 0.819893 | 0.68227 | README.md | pypi |
# Contributing to Opscode Cookbooks
We are glad you want to contribute to Opscode Cookbooks! The first
step is the desire to improve the project.
You can find the answers to additional frequently asked questions
[on the wiki](http://wiki.opscode.com/display/chef/How+to+Contribute).
You can find additional informatio... | /redi-0.15.5.tar.gz/redi-0.15.5/vagrant/cookbooks/apache2/CONTRIBUTING.md | 0.478041 | 0.686107 | CONTRIBUTING.md | pypi |
from redis import Redis, ConnectionPool
import inspect
class Client(object):
REDIS_CMDS = {
"encrypt": "RC.SETENC",
"decrypt": "RC.GETENC",
"hash": "RC.SETHASH",
"b64encode": "RC.SETB64",
"b64decode": "RC.GETB64",
"b64encrypt": "RC.BSETENC",
"b64decrypt": "... | /redicrypt-py-0.3.1.tar.gz/redicrypt-py-0.3.1/redicrypt/client.py | 0.799011 | 0.237211 | client.py | pypi |
# RedIO - Redis for Trio
A Python 3.7+ module for using Redis database in async programs based on the Trio library.
```
pip install redio
```
This module is not ready for production use and all APIs are still likely to change. It works with my applications and performs roughly at the same speed as other Redis module... | /redio-1.0.0.tar.gz/redio-1.0.0/README.md | 0.503174 | 0.861422 | README.md | pypi |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.