content
stringlengths
5
1.05M
import numbers import numpy as np from numpy.linalg import norm import warnings import re from xrayutilities import Experiment,QConversion # package internal imports from xrayutilities import math # from xrayutilities import materials # from xrayutilities import utilities # from xrayutilities import cxrayutilities fro...
"""Terminal input and output prompts.""" from __future__ import print_function from pygments.token import Token import sys from IPython.core.displayhook import DisplayHook from prompt_toolkit.layout.utils import token_list_width class Prompts(object): def __init__(self, shell): self.shell = shell d...
from datetime import datetime, timedelta from django.contrib.auth.models import User from django.core.urlresolvers import reverse from django.test import TestCase from grid.models import Grid from homepage.models import Dpotw, Gotw from package.models import Package, Category class FunctionalHomepageTest(TestCase):...
import logging from celery import shared_task from papermerge.core.ocr.page import ocr_page as main_ocr_page from papermerge.core.ocr import ( COMPLETE, STARTED ) from .models import Document, Folder, Page from .utils import Timer from . import signal_definitions as signals logger = logging.getLogger(__name_...
import itertools from django.views import generic from django.contrib.contenttypes.models import ContentType from django.utils.translation import ugettext_lazy as _ from django.core.urlresolvers import reverse from django.contrib import messages from django.http import HttpResponseRedirect from django.db.models import...
from time import sleep import serial from os.path import exists class NotConnectedError(Exception): '''Error raised when an action needs a connection, but the connection has not been made.''' def needs_connection(f): def decorator(self, *args, **kwargs): if not self.connected: raise NotC...
# Copyright (C) 2016 Nokia Corporation and/or its subsidiary(-ies). import contextlib import os import re import string import errno import datetime from deployment.filelock import FileLock import git def mkdir_p(path): try: os.makedirs(path) except OSError as exc: # Python >2.5 if exc.errn...
''' Created on Jun 3, 2021 @author: immanueltrummer ''' import torch from transformers import AutoTokenizer, AutoModelForSequenceClassification class EntailmentUtil(): """ Methods for checking entailment. """ def __init__(self): """ Initialize models for entailment checks. """ self.tokeni...
from typing import TYPE_CHECKING, Any, Dict, Optional, TypeAlias, Union if TYPE_CHECKING: from aiohttp import ClientResponse _ResponseType: TypeAlias = ClientResponse else: _ResponseType: TypeAlias = None class CurrencypyError(Exception): """Base exception class for the library. Ideally speakin...
import datetime from django.db import models from django.utils.translation import gettext as _ from applications.globals.models import ExtraInfo class Constants: APPROVAL_TYPE = ( ('APPROVED', 'Approved'), ('PENDING', 'Pending'), ) HALL_NO = ( ('HALL-1','hall-1'), ('HAL...
from __future__ import unicode_literals from django.db import models from django.contrib.auth.models import User from base.models import TimeStampedModel # from challenges.models import (Challenge, ) class ChallengeHostTeam(TimeStampedModel): """ Model representing the Host Team for a particular challenge ...
from keras.layers import Input, Dense, Conv2D, MaxPool2D, Flatten, Dropout, Conv2DTranspose # from keras.callbacks import ModelCheckpoint , EarlyStopping from keras.optimizers import Adam,Adagrad from keras.models import Model from keras import backend as K import keras import numpy as np from sklearn.utils import sh...
from tscc.version import __version__
import dash import dash_bootstrap_components as dbc import dash_core_components as dcc import dash_html_components as html from backend import ( get_df_today, get_df_week, get_df_month, get_df_all, get_df_lastmonth, plotting, plotting_temperature_humidity, ) df1 = get_df_today() df2 = get_d...
## @package cnn # Module caffe2.python.cnn from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals from caffe2.python import scope, model_helpers from caffe2.python.model_helper import ModelHelperBase from caffe2.proto import ...
import sys from os.path import isdir, isfile, join rootDir = "../../" configDir = rootDir + "Config/" configFile = join(configDir, "time_of_day.ini") if not isdir(rootDir): print "Root directory does not exist!" sys.exit(0) if not isdir(configDir): print "Config directory does not exist!" ...
#!/usr/bin/env python3 from taptaptap3.proc import plan, ok, out plan(tests=1) ok("Proving it right") out() ## validity: 0 ## ok testcases: 1 / 1 ## bailout: no ## stderr: Proving
class stream_file(object): def __init__(self,filepath): self.m_file_handle=None self.m_file_size =0 self.cur_pos =-1 self.file_name =filepath self.init(filepath) def init(self,filepath): try: self.m_file_handle=open(filepath,'rb') ...
import sys sys.setrecursionlimit(10000000) N, Q = map(int, input().split()) neighbor = {} visited = [-1] for i in range(N - 1): tmpA, tmpB = map(int, input().split()) if tmpA - 1 not in neighbor.keys(): neighbor[tmpA - 1] = [] if tmpB - 1 not in neighbor.keys(): neighbor[tmpB - 1] = [] ...
''' Package support for FreeBSD ''' # Import python libs import logging # Import salt libs import salt.utils log = logging.getLogger(__name__) def __virtual__(): ''' Set the virtual pkg module if the os is FreeBSD ''' return 'pkg' if __grains__['os'] == 'FreeBSD' else False def _check_pkgng(): ...
# -*- cpy-indent-level: 4; indent-tabs-mode: nil -*- # ex: set expandtab softtabstop=4 shiftwidth=4: # # Copyright (C) 2009,2013 Contributor # # 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 #...
# SPDX-FileCopyrightText: (c) 2021 Artёm IG <github.com/rtmigo> # SPDX-License-Identifier: MIT from typing import List, BinaryIO, Optional from dmk.a_base import CodenameKey from dmk.b_cryptoblobs import DecryptedIO from dmk.b_storage_file import BlocksIndexedReader class NameGroupItem: def __init__(self, idx:...
# TODO: avoid import everything from _mnncengine._nn for visable control from _mnncengine._nn import * import _mnncengine._expr as _F import _mnncengine._nn as _nn def load_module_from_file(file_name, input_names, output_names, **kwargs): dynamic = kwargs.get('dynamic', False) shape_mutable = kwargs.get('shap...
import unittest import datetime import os from datetime import timedelta from kostock.configurer import Configurer from kostock.backtester import BackTester from kostock.stockdb import StockDB class BackTesterTestCase(unittest.TestCase): Configurer("config.json") DB = StockDB() def setUp(self) -> None: ...
temp = float(input('Digite a temperatura ')) k = 273.15 + temp f = (temp * 9/5) + 32 print('A temperatura digitada é de {}ºC \n Fahrenheit {}ºF \n Kelvin {}K'.format(temp, k ,f))
# Copyright 2016 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 applica...
# Generated by Django 3.1.5 on 2021-05-20 07:13 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('rotator', '0023_auto_20210507_1137'), ] operations = [ migrations.AlterField( model_name='cropinteraction', name='de...
import numpy as np from src.metrics.abstract_metric import AbstractMetric class F1Score(AbstractMetric): def __init__(self): super().__init__() def get_value(self, confusion_matrix: np.ndarray): diag = np.diag(confusion_matrix) precision = np.mean(np.nan_to_num(diag / confusion_matr...
class ProjectBuilder: '''Object model for building a Python script boilerplate Attributes: lines -- the starting template code for the base file ''' def __init__(self, name, lines, *args, **kwargs): self.name = name self.lines = list(lines) @property def name(): ...
from __future__ import absolute_import, unicode_literals from django.conf.urls import url from wagtail.wagtailimages.views.serve import serve urlpatterns = [ url(r'^([^/]*)/(\d*)/([^/]*)/[^/]*$', serve, name='wagtailimages_serve'), ]
#!/usr/bin/env python from __future__ import print_function import sys import time from math import fmod, pi import unittest import rospy import rostest import tf2_py as tf2 import tf2_ros import PyKDL from std_srvs.srv import Empty class TestBasicLocalization(unittest.TestCase): def setUp(self): self...
def hello_world(): """ This comment indicates this is the version of the first branch This is the second version! It is different. adding a new comment """ print("hello " + "world!")
# -*- coding: utf-8 -*- # # This file is part of apacheconfig software. # # Copyright (c) 2018-2020, Ilya Etingof <etingof@gmail.com> # License: https://github.com/etingof/apacheconfig/LICENSE.rst # from __future__ import unicode_literals import sys from apacheconfig import ApacheConfigError, make_lexer try: imp...
#!/usr/bin/env python import subprocess import sys import os import time import tempfile import argparse EDITOR = os.environ.get('EDITOR', 'vim') verbose = False CHANGE_TEMPLATE = """ Change: new Client: %(client)s User: %(user)s Status: new Description: %(desc)s """ def die(msg): print msg sys.exit(1) ...
from django.shortcuts import render from django.views.generic import TemplateView from django.contrib.auth.mixins import LoginRequiredMixin class IndexView(LoginRequiredMixin, TemplateView): template_name = "protect/index.html" def get_context_data(self, **kwargs): context = super().get_context_data(...
from django.db import models # Create your models here. class Video(models.Model): title = models.CharField(null=True, blank=True, max_length=300) conten = models.TextField(null=True, blank=True) url_image = models.URLField(null=True, blank=True) editors_choice = models.BooleanField(null=True, blank=T...
from typing import List from pygls.types import Diagnostic, Position, Range from textx.exceptions import TextXError from textx_ls_core.features.validate import validate from ..protocol import TextXDocument def _create_diagnostics(doc: TextXDocument) -> List[Diagnostic]: """Creates diagnostics from TextXError o...
from .__version__ import __title__, __description__, __version__ from .client import Client from .models.response import ResponseObject __all__ = ["__description__", "__title__", "__version__", "Client", "ResponseObject"]
import cv2 import json imagePath = "output/gal_0.tif" image = cv2.imread(imagePath) jsonPath = "output/data_0.json" with open(jsonPath, "r") as jsonFile: content = jsonFile.read() data = json.loads(content) print(data[0][0]) for row in range(10): for column in range(10): startY = row * 40 en...
from dataclasses import dataclass from bindings.ows.abstract_reference_base_type import AbstractReferenceBaseType __NAMESPACE__ = "http://www.opengis.net/ows/2.0" @dataclass class AbstractReferenceBase(AbstractReferenceBaseType): class Meta: namespace = "http://www.opengis.net/ows/2.0"
#!/usr/bin/env python # Copyright (c) 2013 dangbinghoo <dangbinghoo@gmail.com> # All rights reserved. # # License: BSD import os import re import array from PyQt5 import QtWidgets, QtGui from PyQt5.QtWidgets import * from PyQt5.QtGui import * from PyQt5.QtCore import * from .EdView import EditorView # code context...
# Copyright (c) Facebook, Inc. and its affiliates # Copyright (c) MTRF authors from sensor_msgs.msg import Image as Image_msg import rospy import numpy as np import skimage import matplotlib.pyplot as plt import warnings from sklearn.exceptions import DataConversionWarning warnings.filterwarnings(action='ignore', cat...
#!/usr/bin/env python import os import sys from io import BytesIO, IOBase import math from collections import Counter def LCSubStr(X, Y, m, n): # Create a table to store lengths of # longest common suffixes of substrings. # Note that LCSuff[i][j] contains the # length of longest common suffix of ...
import random class Knapsack(object): def __init__(self, weight, value, max, nGen, pCross, pmutasi, nPop): self.nGen = 0 self.weight = weight self.value = value self.pCross = 0 self.pmutasi = 0 self.nPop = 0 self.max = max self.result = 0 se...
#!/usr/bin/env python from __future__ import print_function import sys import os import logging import argparse import re import json import shutil import distutils.dir_util import protocols_utils.utils.conversion_tools as conversion_tools from protocols_utils.utils.conversion_tools import ConversionTools from protocol...
import threading from .composed import wraps class Cache(dict): local = threading.local() def __enter__(self): try: stack = self.local.stack except AttributeError: stack = self.local.stack = [] stack.append(self) return self def __exit__(self, *ex...
from .interceptor import *
import torch import numpy as np def ap_frombins(bins, target): target = target.float() bs = target.size(0) linked = [[] for i in range(bs)] above = np.zeros((bs)) idx = -1 for i in range(bs - 1): for j in range(i + 1, bs): if target[i] != target[j]: idx +...
import unittest import jwt import time import os from django.conf import settings from unittest import mock from sparrow_cloud.auth.user import User USER_ID = '1112313123' PAYLOAD = {"uid": "1112313123", "app_id": "app_0000", "exp": int(time.time()+60*60), "iat": int(time.time()), "iss": "backend"} AUTH =...
import PIL from PIL import Image from PIL import ImageTk from tkinter import * from tkinter import ttk from tkinter import filedialog from tkinter import messagebox import sys, os, argparse class Remex: def printHelp(self): pass def _initializeLocations(self): self._minitiles, ...
from scapy.all import * from PacketGenerator import * from helper.ReplayHelper import * from utils.TimeUtils import * def generateReplay(args): ''' Generates (modified) replay traffic for every capture. Parameters: args (Namespace): program arguments Returns: None ''' for p...
# [START composer_kubernetespodoperator] import datetime import json from airflow import models from airflow.contrib.kubernetes import secret from airflow.contrib.operators import kubernetes_pod_operator from airflow.models import Variable from airflow.operators.python_operator import PythonOperator from move_exp_dat...
from django.core.exceptions import ValidationError from django.forms import widgets from django.utils.translation import gettext as _ from django import forms from publications.models import List, Publication from publications.bibtex import parse from publications.utils import populate_from_bib class ImportBibitexForm...
import random import string from model.project import Project def test_delete_project(app, soap): if len(app.project.get_list()) == 0: app.project.create(Project(name=random_string("project_of", 10), description=random_string("description:", 50))) old_projects = soap.get_list() project = random.ch...
# Copyright 2020-2021 OpenDR European Project # # 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 agree...
import pytest import sys import os import numpy as np from anytree import RenderTree from pvtrace.scene.scene import Scene from pvtrace.scene.node import Node from pvtrace.geometry.sphere import Sphere from pvtrace.geometry.intersection import Intersection class TestIntersection: def test_init(self): ...
import torch from .defs import NONLINEARITIES, TimeDerivative, StepPrediction class NNKernel(torch.nn.Module): def __init__(self, input_dim, hidden_dim, output_dim, nonlinearity=torch.nn.Tanh, predict_type="deriv"): super().__init__() frozen_linear = torch.nn.Linear(input_dim, hid...
''' Copyright 2015 Matthew Loper, Naureen Mahmood and the Max Planck Gesellschaft. All rights reserved. This software is provided for research purposes only. By using this software you agree to the terms of the SMPL Model license here http://smpl.is.tue.mpg.de/license More information about SMPL is available here htt...
from utils.QtCore import * from utils.settings import Settings from widgets.CustomTooltip.CustomTooltip import CustomTooltip class CustomAppButton(QPushButton): def __init__( self, parent, app_parent = None, tooltip_text = "", bg_color_hover = "#404040", bg_color_p...
from collections import defaultdict for line in open("../20_clusters_eggnog/NOG2EurNOG.tab"): line = line.strip().split('\t') for eur in line[1].split(';'): eur2NOG[eur].append(line[0]) cog2eur = defaultdict(list) for f in glob.glob('queries_split/*'): f = f.replace('queries_split/', '').replace("...
# Copyright (C) 2015-2021 Virgil Security, Inc. # # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # (1) Redistributions of source code must retain the above copyright # notice, this li...
# This file is generated by objective.metadata # # Last update: Sun Aug 2 18:47:32 2015 import objc, sys if sys.maxsize > 2 ** 32: def sel32or64(a, b): return b else: def sel32or64(a, b): return a if sys.byteorder == "little": def littleOrBig(a, b): return a else: de...
#!/usr/bin/env python # -*- coding: utf-8 -*- #--------------------------------- #Start of contentHome.py #--------------------------------- ################################################# #Libraries import dash import dash_core_components as dcc import dash_html_components as html import dash_bootstrap_components...
"""One of the main goals of this lesson is to help you develop your ability to look at some code and identify its time complexity—and then describe this time complexity using Big O notation. We will use this graph as a referece and reminder of the importance of the run time of an algorithm. We have the number of input...
from .nested_sampling import NestedSampling
import fortnitepy from typing import Union from enum import Enum class MessageType(Enum): PARTY = 0 FRIEND = 1 class MessageContext(fortnitepy.message.MessageBase): def __init__(self, message: Union[fortnitepy.FriendMessage, fortnitepy.PartyMessage] # noqa ) -> None: ...
""" Common functions and nuts. """ from __future__ import print_function from constants import * from glob import glob import os os.environ['TF_CPP_MIN_LOG_LEVEL'] = '3' # Suppress tensorflow warnings os.environ['KERAS_BACKEND'] = 'tensorflow' os.environ["CUDA_DEVICE_ORDER"] = "PCI_BUS_ID" os.environ["CUDA_VISIBLE_...
# jsb/plugs/socket/jira.py """ jira.py - jsonbot module for performing lookups on a jira server Copyright 2011, Richard Bateman Special thanks to Sean B. Palmer for his phenny module; many of the ideas for this were adapted from that plugin http://inamidst.com/phenny/ """ ## jsb imports from jsb.lib.callbacks impo...
import sys from flask import Flask, request, jsonify from flask_cors import CORS from tokenizer_tools.tagset.NER.BILUO import BILUOSequenceEncoderDecoder from hanzi_char_lookup_feature.n_gram_lookup.ngrams_feature import generate_lookup_feature, load_data_set decoder = BILUOSequenceEncoderDecoder() app = Flask(__n...
from unittest import TestCase from openapitutorial.entity.gendar import Gendar class TestGendar(TestCase): def test_serializable(self): value = Gendar.FEMALE.to_serializable() self.assertEqual(Gendar.from_serializable(value), Gendar.FEMALE)
# -*- coding: utf-8 -*- # Copyright 2013,2014,2015,2016 Georgia Institute of Technology. # # 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 req...
"""Recursive and Iterative solutions.""" class LinkedList: """Linked List class.""" def __init__(self, val): """Create a linked list.""" self.val = val self.next = None def iterative_merge(l1, l2): """Solved in an iterative way.""" prehead = LinkedList(-1) pre = prehead ...
import argparse import pandas as pd import numpy as np import pickle from pprint import pprint from sklearn.ensemble import RandomForestClassifier from sklearn.datasets import make_classification from sklearn.model_selection import RandomizedSearchCV from sklearn.model_selection import GridSearchCV from sklearn.model_s...
#!/usr/bin/env python from __future__ import absolute_import, division, print_function, unicode_literals from splunklib.searchcommands import dispatch, StreamingCommand, Configuration, Option, validators import sys import geopy from geopy.distance import vincenty @Configuration() class GeoDistCommand(StreamingCommand...
#! /usr/bin/env python import genomon_pipeline.stage_task as st class Intron_retention(st.Stage_task): task_name = "intron_retention" script_template = """ #!/bin/bash # # Set SGE # #$ -S /bin/bash # set shell in UGE #$ -cwd # execute at the submitted dir pwd # pr...
from turbogears.database import PackageHub # import some basic SQLObject classes for declaring the data model # (see http://www.sqlobject.org/SQLObject.html#declaring-the-class) from sqlobject import SQLObject, SQLObjectNotFound, RelatedJoin # import some datatypes for table columns from SQLObject # (see http://www.sql...
from django.db import models class Pokemon(models.Model): title_ru = models.CharField(max_length=200, verbose_name='Имя на русском') title_en = models.CharField(max_length=200, verbose_name='Имя на английском', blank=True) title_jp = models.CharField(max_length=200, verbose_name='Имя на японском', blank=T...
from PIL import ImageGrab from autocorrect import Speller from PIL import Image import pytesseract import requests import re import cv2 import time import numpy as np import pyautogui import random from colorthief import ColorThief import io import json ''' Path is where the hint hints file is located. Hint positions i...
from django.contrib.auth.models import User from django.test import TestCase from hc.accounts.models import Profile class TeamAccessMiddlewareTestCase(TestCase): def test_it_handles_missing_profile(self): user = User(username="ned", email="ned@example.org") user.set_password("password") u...
#!/usr/bin/env python """ WBEM namespaces """ import sys import lib_util import lib_wbem import lib_common from lib_properties import pc def Main(): cgiEnv = lib_common.ScriptEnvironment(can_process_remote=True) cimom_url = cgiEnv.GetHost() grph = cgiEnv.GetGraph() # There is no consensus on the ...
from typing import Optional from pydantic import BaseSettings, PostgresDsn from pydantic.types import SecretStr class Config(BaseSettings): JWT_ALGORITHM: str = "HS256" POSTGRES_DSN: PostgresDsn CELERY_BROKER_URL: str # For modules to provide config for minio client S3_ENDPOINT: Optional[str] ...
from kongoauth.authentication import KongOAuthAuthentication from kongoauth.permissions import KongOAuthPermission from rest_framework import routers from django.db import models from rest_framework import serializers, viewsets class Example(models.Model): name = models.CharField(max_length=10) class ExampleSer...
''' Copyright (c) 2014-2017, Bitnine Inc. 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, ...
def checkRange(x, y, img) -> bool: if x >= 0 and x < img.shape[0] and y >= 0 and y < img.shape[1]: return True return False
import requests, logging as log from openpyxl import Workbook, load_workbook #Logging Config log.basicConfig(filename='ActivityLog.log', level=log.DEBUG, format='%(asctime)s %(levelname)-8s %(message)s', datefmt='%Y-%m-%d %H:%M:%S') #Variables wb = load_workbook('data.xlsx') #name of data file goes here ws = ...
from .faked import * from .help import setup
from GraphManager import * import time row = 25 col = 25 class InvalidDataFormat(Exception): pass class DataManager: def __init__(self, row, column, inputData = []): self.connector = GraphManager() self.inputData = inputData self.outputData = [] self.row = row self.col ...
from hashlib import md5 from datetime import datetime MARVEL_PUBLIC_KEY = "0000000000000000000000000000000" MARVEL_PRIVATE_KEY = "000000000000000000000000000000000000" def get_hash_ts() -> tuple: ts = _get_ts() s = str(ts) + MARVEL_PRIVATE_KEY + MARVEL_PUBLIC_KEY my_hash = md5(s.encode()) return my_h...
import numpy as np import argparse if __name__ == "__main__": parser = argparse.ArgumentParser(description='Deploying command') parser.add_argument("command", nargs=argparse.REMAINDER) args = parser.parse_args() print(args.command)
# -*-coding:Latin-1 -* V = [0, 1, 2] C = [9, 8] for i in V: print(V[i], " ", C[0], " ", C[1])
#!/usr/bin/python import queue import threading import time import random in_q = queue.Queue() out_q = queue.Queue() def worker(): while True: x = in_q.get() if x is None: break do_stuff(x) in_q.task_done() def do_stuff(x): out_q.put(x) def main(): threads =...
# -*- encoding: utf-8 -*- """ @File : permissionDepends.py @Time : 2020/4/11 17:19 @Author : chise @Email : chise123@live.com @Software: PyCharm @info :权限相关的依赖 """
import jwt from django.contrib import auth from django.contrib.auth import get_user_model from django.shortcuts import render from rest_framework import viewsets, status, permissions from rest_framework.response import Response from rest_framework.views import APIView from rest_framework import mixins from rest_framewo...
from django.db import models from .helpers import MockRequest from .testcases import TestCase from ..models import Answer, Details, Invite, Party, Person from ..serializers import PartySerializer from ..views import PartyViewSet class DynamicQuerySetMixinTestCase(TestCase): def setUp(self): self.viewset_...
import Globals import glob import re import datetime import os DATESTAMP_RE = re.compile("(?P<full>(?P<year>\\d{4})(?P<month>\\d{2})(?P<day>\\d{2}))") class ComicBucket(object): ''' The ComicBucket processes and contains all the comics in the system. That is, it is what handles copying all "active" comic...
######### # Copyright (c) 2015-2019 Cloudify Platform Ltd. 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 ...
from schema_registry.serializers.message_serializer import MessageSerializer from schema_registry.serializers.faust_serializer import FaustSerializer
# Copyright 2018 The Cornac 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 ...
import logging from typing import Optional, Union, Any, Mapping import marshmallow from happyly._deprecations.utils import will_be_removed from happyly.logs.request_id import RequestIdLogger from happyly.serialization import DUMMY_SERDE from happyly.serialization.json import BinaryJSONSerializerForSchema from ..subsc...
import MRImageAnalysis as mri import matplotlib.pyplot as plt import numpy as np import sys class TransferFunctions: def __init__(self, w, K_trans, v_e, v_p=None, F_p=None, PS=None): self.w = w self.defaults = { 'K_trans': K_trans, 'F_p' : F_p, 'v_p' : v_p, 'v_e' : v_e, 'PS' : PS } ...