text
stringlengths
2
999k
import os import zipfile import shutil def utp_print(s): print"utp>" + s def command(cmd, visble=True): if visble: utp_print(cmd) ret = os.system(cmd) return ret # return as string list def command2(cmd, visble=True): if visble: utp_print(cmd) r = os.popen(cmd) lines = r.r...
# coding=utf-8 # -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may ...
EMAIL = 'auth.googpy@gmail.com' USERNAME = 'auth.googpy' PASSWORD = 'MCPxnwh9V5Xs7Yc6' def googinit(): googauthcreds() def googauthcreds(): print(USERNAME) print(EMAIL) print(PASSWORD)
import argparse, access, mstrans parser = argparse.ArgumentParser(description=__doc__) parser.add_argument(dest='text', type=str, help='a string to translate') parser.add_argument('-t', '--to', dest='to_lang', type=str, default='en', help='to language') parser.add_argument('-f',...
__all__ = ['__version__'] __version__ = '1.0.42'
import pandas as pd import numpy as np def construct_freq_df(df_copy): ''' Construct a dataframe such that indices are seperated by delta 1 min from the Market Data and put it in a format that markov matrices can be obtained by the pd.crosstab() method ''' #This is here in case user passes the...
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
# -*- coding: utf-8 -*- # Copyright (c) 2019, Frank Nyarkoh and contributors # For license information, please see license.txt from __future__ import unicode_literals import frappe from frappe.model.document import Document class RoomType(Document): pass
import logging import os import sys import boto3 from botocore import UNSIGNED from botocore.config import Config from tqdm import tqdm _logger = logging.getLogger(__name__) _DEFAULT_BUCKET = 'brain-score-models' _DEFAULT_REGION = 'us-east-1' _NO_SIGNATURE = Config(signature_version=UNSIGNED) def download_folder(f...
from django.db import models from pygments.lexers import get_all_lexers from pygments.styles import get_all_styles # Create your models here. LEXERS = [item for item in get_all_lexers() if item[1]] LANGUAGE_CHOICES = sorted([(item[1][0], item[0]) for item in LEXERS]) STYLE_CHOICES = sorted([(item, item) for item in ...
from __future__ import division, print_function import numpy as np import autogalaxy as ag grid = np.array([[1.0, 1.0], [2.0, 2.0], [3.0, 3.0], [2.0, 4.0]]) class TestPointFlux: def test__constructor(self): point_source = ag.ps.PointFlux(centre=(0.0, 0.0), flux=0.1) assert point_s...
from amadeus.client.decorator import Decorator class Location(Decorator, object): def __init__(self, client, location_id): Decorator.__init__(self, client) self.location_id = location_id def get(self, **params): ''' Returns details for a specific airport. .. code-bloc...
import base64 import collections import datetime import importlib import inspect import json import logging import os import sys import tarfile import traceback from builtins import str import boto3 from werkzeug.wrappers import Response # This file may be copied into a project's root, # so handle both scenarios. try...
# Volatility # Copyright (C) 2007-2013 Volatility Foundation # # This file is part of Volatility. # # Volatility is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your o...
# Copyright 2020, The TensorFlow Federated Authors. # # 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 o...
from __future__ import absolute_import import numpy as np import torch from torch import nn import os from collections import OrderedDict from torch.autograd import Variable import itertools from scipy.ndimage import zoom import fractions import functools import skimage.transform from IPython import embed from .base_m...
#!/usr/bin/python3 """ Flask App that integrates with AirBnB static HTML Template """ from api.v1.views import app_views from flask import Flask, jsonify, make_response, render_template, url_for from flask_cors import CORS, cross_origin from flasgger import Swagger from models import storage import os from werkzeug.exc...
import numpy as np def bubble_sort(arr): """ Performs a bubble sort algorithm - Time complexity: O(n²) Args: arr (list): List to sort Returns: (list): Sorted list """ j = len(arr) - 1 while j >= 0: i = 0 while i < j: if arr[i] > arr[i+1]...
import requests from datetime import datetime from .base import BaseChannel from ..models import Video, VideoResolution, Brand class Kika(BaseChannel): BASE_API_URL = "https://prod.kinderplayer.cdn.tvnext.tv/api" def all_videos(self): r = requests.get(f"{self.BASE_API_URL}/videos") videos = ...
MICROSERVICES = { "LOCATION_MICROSERVICES": [ # Map locations to their microservices {"module": "intelligence.microsoftvideo.location_video_microservice", "class": "LocationVideoMicroservice"} ] }
"""Tests for the implementation of RootOf class and related tools. """ from sympy.polys.polytools import Poly from sympy.polys.rootoftools import rootof, RootOf, CRootOf, RootSum from sympy.polys.polyerrors import ( MultivariatePolynomialError, GeneratorsNeeded, PolynomialError, ) from sympy import ( ...
#!/usr/bin/python import pyglet class Menu: def __init__(self, img_provider, menu_items, window_height, window_width, title=None, color=(255, 255, 255, 255), selection_color=(34, 226, 53, 255), ...
from typing import Dict, List import numpy as np import pytest from jina.drivers.craft import SegmentDriver from jina.drivers.helper import array2pb from jina.executors.crafters import BaseSegmenter from jina.proto import jina_pb2, uid class MockSegmenter(BaseSegmenter): def __init__(self, *args, **kwargs): ...
# -*- coding: utf-8 -*- ''' Module for viewing and modifying sysctl parameters ''' from __future__ import absolute_import, unicode_literals, print_function # Import python libs import os # Import salt libs import salt.utils.files from salt.exceptions import CommandExecutionError from salt.ext import six # Define the...
# -*- coding: utf-8 -*- """ This code is auto generated from troposphere_mate.code_generator.__init__.py scripts. """ import sys if sys.version_info.major >= 3 and sys.version_info.minor >= 5: # pragma: no cover from typing import Union, List, Any import troposphere.dms from troposphere.dms import ( Dynamo...
# We need to maintain the version here since it needs to be updated by the build process on GitHub config_additional_config = { 'module_version': '1.3.3.dev0', }
#!/usr/bin/python # -*- coding: utf-8 -*- # Создать класс Circle, конструктор которого принимает радиус. Класс должен иметь два метода, вычисляющие площадь и длину окружности. import math class Circle: r = 0 def __init__(self, r): self.r = r def area(self): return math.pi * self.r * self....
from __future__ import annotations from spark_auto_mapper_fhir.fhir_types.uri import FhirUri from spark_auto_mapper_fhir.value_sets.generic_type import GenericTypeCode from spark_auto_mapper.type_definitions.defined_types import AutoMapperTextInputType # This file is auto-generated by generate_classes so do not edi...
# automatically generated by the FlatBuffers compiler, do not modify # namespace: aghast_generated import flatbuffers class FractionBinning(object): __slots__ = ['_tab'] @classmethod def GetRootAsFractionBinning(cls, buf, offset): n = flatbuffers.encode.Get(flatbuffers.packer.uoffset, buf, offse...
# -*- coding: utf-8 -*- # # Configuration file for the Sphinx documentation builder. # # This file does only contain a selection of the most common options. For a # full list see the documentation: # http://www.sphinx-doc.org/en/stable/config # -- Path setup ------------------------------------------------------------...
# 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, software # d...
class ProjectStatus: def __init__(self, name): self.name = name self.icon = None self.status = None def add_icon(self, icon): self.icon = icon def set_status(self, status): self.status = status class ProjectStatusDictionary(object): def __init__(self): ...
#!/usr/bin/env python # # specification_curve documentation build configuration file, created by # sphinx-quickstart on Fri Jun 9 13:47:02 2017. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this # autogenerated f...
from django.forms import ModelForm from .models import Claim class ClaimForm(ModelForm): class Meta: model = Claim fields = ['name', 'phone'] msg_limit = "Превышено допустимое количество символов" msg_null = "Поле не может быть пустым" def clean(self): cleaned_data = super(Cl...
from django.urls import path from . import views urlpatterns = [ path('', views.IndexPageView.as_view(), name='index'), ]
""" Backs up and restores a settings file to Dropbox. This is an example app for API v2. """ import sys import dropbox from dropbox.files import WriteMode from dropbox.exceptions import ApiError, AuthError # Add OAuth2 access token here. # You can generate one for yourself in the App Console. # See <https://blogs.dro...
# -*- coding:utf-8 -*- # Author: hankcs # Date: 2020-12-03 14:24 from hanlp_demo import block_windows from hanlp.common.dataset import SortingSamplerBuilder from hanlp.common.transform import NormalizeCharacter from hanlp.components.mtl.multi_task_learning import MultiTaskLearning from hanlp.components.mtl.tasks.consti...
import matplotlib.pyplot as plt def controi_grafico(prop1, prop2, dado1, dado2, estilo, cor, marcador, titulo, msg_x, msg_y): plt.figure(figsize=(prop1, prop2)) plt.plot(dado1, dado2, linestyle=estilo, color=cor, marker=marcador) plt.title(titulo) plt.xlabel(msg_x) plt.ylabel(msg_y) plt.show()
"""Support for Wink sensors.""" import logging from homeassistant.const import TEMP_CELSIUS from . import DOMAIN, WinkDevice _LOGGER = logging.getLogger(__name__) SENSOR_TYPES = ["temperature", "humidity", "balance", "proximity"] def setup_platform(hass, config, add_entities, discovery_info=None): """Set up t...
import os import logging import numpy as np import pandas as pd import matplotlib import matplotlib.pyplot as plt import matplotlib.patches as patches from colour import Color class TradingEnv: def __init__(self, custom_args, env_id, obs_data_len, step_len, sample_len, df, fee, initial_budget, n_...
"""Worker Task Consumer Bootstep.""" from __future__ import absolute_import, unicode_literals from kombu.common import QoS, ignore_errors from celery import bootsteps from celery.utils.log import get_logger from .mingle import Mingle __all__ = ('Tasks',) logger = get_logger(__name__) debug = logger.debug class T...
from multiprocessing import cpu_count SEED = 777 TEMP_DIRECTORY = "temp/data" RESULT_FILE = "result.tsv" SUBMISSION_FILE = "predictions.txt" RESULT_IMAGE = "result.jpg" GOOGLE_DRIVE = False DRIVE_FILE_ID = None MODEL_TYPE = "xlmroberta" MODEL_NAME = "xlm-roberta-large" transformer_config = { 'output_dir': 'temp/o...
# Copyright (c) LinkedIn Corporation. All rights reserved. Licensed under the BSD-2 Clause license. # See LICENSE in the project root for license information. import setuptools from os import path this_directory = path.abspath(path.dirname(__file__)) with open(path.join(this_directory, 'README.md'), encoding='utf-8') a...
from queue import Queue from DS.Graph.graph import * def build_distance_table(graph, source): distance_table = {} for i in range(graph.num_vertices): distance_table[i] = (None, None) distance_table[source] = (0, source) queue = Queue() queue.put(source) while not queue.empty(): ...
#!/usr/bin/env python3 # Copyright (c) 2014-2016 The Bitcoin Core developers # Distributed under the MIT software license, see the accompanying # file COPYING or http://www.opensource.org/licenses/mit-license.php. """Test the wallet accounts properly when there is a double-spend conflict.""" from test_framework.test_f...
#!/usr/bin/env python3 import sys import qm3.actions.paths import qm3.maths.interpolation import qm3.maths.grids class pmf2d: def __init__( self, data ): self.size = 2 self.mass = [ 1., 1. ] self.func = .0 self.coor = [ 0, 0 ] self.grad = [ 0, 0 ] self.hess = [ 0, 0, 0 ] self.grid = qm3.maths.grids.gri...
# -*- coding: utf-8 -*- # PLEASE DO NOT EDIT THIS FILE, IT IS GENERATED AND WILL BE OVERWRITTEN: # https://github.com/ccxt/ccxt/blob/master/CONTRIBUTING.md#how-to-contribute-code from ccxt.async_support.base.exchange import Exchange import hashlib from ccxt.base.errors import ExchangeError from ccxt.base.errors impor...
# Auto generated by generator.py. Delete this line if you make modification. from scrapy.spiders import Rule from scrapy.linkextractors import LinkExtractor XPATH = { 'name' : "//h2[@id='hTitleDeal']/span/p", 'price' : "//p[@class='pGiaTienID']/strong", 'category' : "", 'description' : "//div[@class='d...
#!/usr/bin/env python # Copyright (c) 2007, Secure64 Software Corporation # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to ...
# Copyright 2020 Google LLC # # 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, so...
from django.conf import settings # Name of the referrer's get parameter name GET_PARAMETER = getattr(settings, 'REFERRAL_GET_PARAMETER', 'ref') # Name of the session variable storing the detected referrer SESSION_KEY = getattr(settings, 'REFERRAL_SESSION_KEY', 'referrer') # Should unknown referrers be auto created? ...
from haven import haven_utils as hu import itertools, copy EXP_GROUPS = {} model_list = [] # for loss_weight in [0.001]: # model_list += [ # {'name':'semseg', 'loss':'toponet', # 'loss_weight': loss_weight, # 'base':'fcn8_vgg16', # ...
#!/usr/bin/env python # # Copyright (c) 2013 In-Q-Tel, Inc/Lab41, 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...
import torch import graphgallery.nn.models.dgl as models from graphgallery.data.sequence import FullBatchSequence from graphgallery import functional as gf from graphgallery.gallery.nodeclas import NodeClasTrainer from graphgallery.gallery.nodeclas import DGL @DGL.register() class MixHop(NodeClasTrainer): ...
##scrapes nba.com/stats #import the libraries from bs4 import BeautifulSoup import requests import numpy import pyodbc import pandas as pd #from datetime import * #from dateutil.relativedelta import * nba_months = ['october', 'november', 'december', 'january', 'feburary', 'march', 'april', 'june'] # Scrape https:/...
""" Django settings for serveup project. Generated by 'django-admin startproject' using Django 3.0.7. For more information on this file, see https://docs.djangoproject.com/en/3.0/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/3.0/ref/settings/ """ import os im...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' Roomba api web server ''' import asyncio from aiohttp import web import base64 import logging class webserver(): VERSION = __version__ = "2.0e" api_get = {'time' : 'utctime', 'bbrun' : 'bbrun', ...
from distutils.log import WARN from pdb import post_mortem from typing import Dict, List, Optional, Tuple import torch from torch import Tensor from torch.nn import Embedding from torch.utils.data import DataLoader from torch_sparse import SparseTensor from torch_geometric.typing import EdgeType, NodeType, OptTensor ...
import re def formatText(input): output = [] for line in input: line = _removeSpace(line) if (_isComment(line) or _isEmpty(line)): continue else: output.append(line) return output def _removeSpace(input): headTrailSpace = re.compile(r'\s*') outpu...
from .base import * # noqa DATABASES = { 'default': { 'ENGINE': 'django.db.backends.postgresql_psycopg2', 'NAME': 'docs', 'USER': 'postgres', # Not used with sqlite3. 'PASSWORD': '', 'HOST': '10.177.73.97', 'PORT': '', } } DEBUG = False TEMPLATE_DEBUG = False...
from . import hdf5
""" WSGI config for todo_web project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/3.2/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault('DJANGO_SETT...
import numpy as np import pandas as pd import os from scipy.sparse import coo_matrix from pathlib import Path p = Path(os.getcwd()).parents[0] # set file paths schooldatapath = '/Users/lsh1514285/jdrive/SCDATA/' filename = 'Autumn_Census_Addresses_2020.txt' filename_hh_id = 'aut_hh_v2.csv' postcode_path = str(p...
# Generated by the protocol buffer compiler. DO NOT EDIT! # source: logutil.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descriptor from google.protobuf import message as _m...
# Templating from django import template register = template.Library() # Models from correx.models import Change from django.contrib.auth.models import User from django.contrib.sites.models import Site from django.db.models import get_app, get_model from django.contrib.contenttypes.models import ContentType # Text ma...
from unittest import TestCase from prometheus_client.registry import CollectorRegistry from app.prom.metrics.general.rman_curr_backup import RmanCurrBackup, SID, CONTEXT, TIME_REMAINING, SOFAR, TOTALWORK from tests.helpers import setUpApp, with_context class TestRmanCurrBackup(TestCase): def setUp(self): ...
from django.shortcuts import render, render_to_response,redirect, get_object_or_404 from django.http.response import HttpResponse,Http404 from .models import User, Domain, Items, Relation from django.utils import timezone from django.views import View,generic from django.urls import reverse import os # Permissions fro...
import time from typing import Any, Dict, List, Optional from enum import Enum from datetime import datetime import requests import json from airflow.exceptions import AirflowException from airflow.providers.facebook.ads.hooks.ads import FacebookAdsReportingHook from facebook_business.api import FacebookAdsApi from f...
#!/usr/bin/env python3 import argparse from os import listdir, makedirs, path import pandas as pd import shutil from re import sub, match import sys import webbrowser import subprocess from glob import glob try: import Tkinter as tk # Python2 except ImportError: import tkinter as tk # Python3 from tkinter....
import recordlinkage as rl from recordlinkage.index import Block from recordlinkage.datasets import load_febrl1, load_febrl4 from recordlinkage.types import is_pandas_2d_multiindex import pandas as pd def test_annotation_link(tmp_path): path = tmp_path / "febrl_annotation_link.json" # get febrl4 file d...
""" transparent.py - Several transparent proxy helpers """ from pypy.interpreter import gateway from pypy.interpreter.error import OperationError, operationerrfmt from pypy.objspace.std.proxyobject import * from pypy.objspace.std.typeobject import W_TypeObject from rpython.rlib.objectmodel import r_dict from rpython....
# Pyrogram - Telegram MTProto API Client Library for Python # Copyright (C) 2017-2021 Dan <https://github.com/delivrance> # # This file is part of Pyrogram. # # Pyrogram is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published # by the Free...
# -*- coding: utf-8 -*- """Console script for squarish.""" import sys import click @click.command() def main(args=None): """Console script for squarish.""" click.echo("Replace this message by putting your code into " "squarish.cli.main") click.echo("See click documentation at http://click....
from typing import Union, List, Optional from pyspark.sql.types import StructType, StructField, StringType, ArrayType, DataType # This file is auto-generated by generate_schema so do not edit it manually # noinspection PyPep8Naming class Encounter_LocationSchema: """ An interaction between a patient and heal...
from __future__ import absolute_import, division, print_function import os import unittest import zlib from io import BytesIO from multiprocessing import Pool from tempfile import mkstemp import numpy as np from bigarray import MmapArray, MmapArrayWriter np.random.seed(8) # =======================================...
import torch import torch.utils.model_zoo as model_zoo import os from collections import OrderedDict def load_checkpoint(model, checkpoint_path, use_ema=False): if checkpoint_path and os.path.isfile(checkpoint_path): checkpoint = torch.load(checkpoint_path) state_dict_key = '' if isinstanc...
import logging from marshmallow import ValidationError, post_load from marshmallow_jsonapi import Schema, fields from timeswitch.auth.dao import User class NullHandler(logging.Handler): def emit(self, record): pass logging.getLogger(__name__).addHandler(NullHandler()) LOGGER = logging.getLogger(__name_...
import os import sys from subprocess import Popen from typing import Any, Dict, List # noqa try: import click except ImportError: sys.stderr.write('It seems python-dotenv is not installed with cli option. \n' 'Run pip install "python-dotenv[cli]" to fix this.') sys.exit(1) from .main...
# Generated by Django 2.1.2 on 2019-04-15 01:45 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('canvases', '0001_initial'), ] operations = [ migrations.AddField( model_name='canvas', name='is_starting_page', ...
def do_stuff(): print("the good stuff")
"""Config flow for Radio Thermostat integration.""" from __future__ import annotations import logging from socket import timeout from typing import Any from radiotherm.validate import RadiothermTstatError import voluptuous as vol from homeassistant import config_entries from homeassistant.components import dhcp from...
import tensorflow as tf from kernels.base import BaseKernel tf.enable_eager_execution() tf.executing_eagerly() import numpy as np __author__ = "Stefano Campese" __version__ = "0.1.2" __maintainer__ = "Stefano Campese" __email__ = "sircampydevelop@gmail.com" class PSpectrumKernel(BaseKernel): """ P-Spectr...
# Copyright (c) 2017, The MITRE Corporation. All rights reserved. # See LICENSE.txt for complete terms. import unittest from mixbox.vendor.six import u from cybox.common import MeasureSource from cybox.test import EntityTestCase class TestMeasureSource(EntityTestCase, unittest.TestCase): klass = MeasureSource ...
import os from rjgtoys.yaml import yaml_load path = os.path.join(os.path.dirname(__file__), 'tutorial2.yaml') with open(path, 'r') as src: data = yaml_load(src) print(data)
"""App API serializers. """ import logging from drf_extra_fields.fields import Base64ImageField from rest_framework import serializers from ...camera_tasks.api.serializers import CameraTaskSerializer from ...camera_tasks.models import CameraTask from ...general.shortcuts import drf_get_object_or_404 from ..constants...
"""Common utilities to search nodes in the current scene.""" import logging import re from maya import cmds LOG = logging.getLogger(__name__) __all__ = ["regex"] def regex(expression): """Find nodes based on regular expression. Arguments: expression (str): The regex that should match the node name...
sum = 0 for i in range(0,100): num = int(input()) sum+=num print(sum)
__all__ = [ 'utils','Filter']
import os import sys import tensorflow as tf BASE_DIR = os.path.dirname(os.path.abspath(__file__)) sys.path.append(BASE_DIR) sys.path.append(os.path.join(BASE_DIR, 'models')) sys.path.append(os.path.join(BASE_DIR, 'tf_utils')) import tf_util from pointSIFT_util import pointSIFT_module, pointSIFT_res_module, pointnet_s...
from __future__ import print_function import FWCore.ParameterSet.Config as cms ## L1REPACK FULL: Re-Emulate all of L1 and repack into RAW from Configuration.Eras.Modifier_stage2L1Trigger_cff import stage2L1Trigger def _print(ignored): print("L1T WARN: L1REPACK:CalouGT (intended for 2016/2017 data) only support...
import discord from discord.ext import commands import typing import asyncio # Importa a função predicate do mod blacklist, que retorna True ou False, usado como decorator from cogs._blacklist import is_blacklisted class velha(commands.Cog): def __init__(self, bot): self.bot = bot @commands.Cog.list...
# -*- coding: utf-8 -*- # Generated by Django 1.9.8 on 2016-11-13 13:46 from __future__ import unicode_literals from django.conf import settings from django.db import migrations, models import django.db.models.deletion import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ...
from rest_framework import serializers from apps.products.models import Amount, Product from apps.inventories.models import (Place, PlaceMember, InventoryItem, Purchase, P...
#!/usr/bin/env python from tools.load import LoadMatrix import shogun as sg lm=LoadMatrix() traindat = lm.load_dna('../data/fm_train_dna.dat') testdat = lm.load_dna('../data/fm_test_dna.dat') parameter_list=[[traindat,testdat],[traindat,testdat]] def kernel_linear_string (fm_train_dna=traindat,fm_test_dna=testdat): ...
""" Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this ...
# -*- coding: utf-8 -*- # Generated by Django 1.10.3 on 2017-10-16 16:38 from __future__ import unicode_literals import django.contrib.gis.db.models.fields from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('api', '0010_remove_metadataobservation_municipali...
#!/usr/bin/env python # # This file is part of pyasn1-modules software. # # Copyright (c) 2005-2018, Ilya Etingof <etingof@gmail.com> # License: http://snmplabs.com/pyasn1/license.html # # PKCS#1 syntax # # ASN.1 source from: # ftp://ftp.rsasecurity.com/pub/pkcs/pkcs-1/pkcs-1v2.asn # # Sample captures could be obtained...
import os from selenium import webdriver from selenium.webdriver.support.ui import WebDriverWait as wait from selenium.webdriver.support import expected_conditions as EC from selenium.webdriver.common.by import By from selenium.webdriver.common.keys import Keys from selenium.webdriver.chrome.options import Options from...
# AuthClientCredential.py # # Copyright (C) 2018-2019 OSIsoft, LLC. All rights reserved. # # THIS SOFTWARE CONTAINS CONFIDENTIAL INFORMATION AND TRADE SECRETS OF # OSIsoft, LLC. USE, DISCLOSURE, OR REPRODUCTION IS PROHIBITED WITHOUT # THE PRIOR EXPRESS WRITTEN PERMISSION OF OSIsoft, LLC. # # RESTRICTED RIGHTS LEGEND #...
from __future__ import absolute_import from __future__ import division from __future__ import print_function from __future__ import unicode_literals from builtins import range from builtins import super import mock import string import unittest from parameterized import parameterized import random import json from ppri...