index
int64
repo_name
string
branch_name
string
path
string
content
string
import_graph
string
6,113
gr33ndata/irlib
refs/heads/master
/irlib/matrixcooccurrence.py
''' Informations Retrieval Library ============================== MatrixCooccurrence: You give it a Matrix, and it creates new co-occurrence matrix of its features ''' # Author: Tarek Amr <@gr33ndata> import sys, math from matrix import Matrix from superlist import SuperList from itertools import permutations cla...
{"/tests/__init__.py": ["/tests/TestLM.py", "/tests/TestSuperList.py", "/tests/TestPreprocessor.py", "/tests/TestMatrix.py", "/tests/TestMetrics.py", "/tests/TestProgress.py", "/tests/TestAnalysis.py", "/tests/TestEvaluation.py"]}
6,114
gr33ndata/irlib
refs/heads/master
/examples/twitter/search.py
# Search in tweets import os, sys # Adding this to path to be able to import irlib sys.path.append('../../') from irlib.preprocessor import Preprocessor from irlib.matrix import Matrix def readfiles(fold_path='all-folds/fold1/'): prep = Preprocessor() mx = Matrix() files = os.listdir(fold_path) fo...
{"/tests/__init__.py": ["/tests/TestLM.py", "/tests/TestSuperList.py", "/tests/TestPreprocessor.py", "/tests/TestMatrix.py", "/tests/TestMetrics.py", "/tests/TestProgress.py", "/tests/TestAnalysis.py", "/tests/TestEvaluation.py"]}
6,115
gr33ndata/irlib
refs/heads/master
/tests/__init__.py
import os import sys import irlib from tests.TestLM import TestLM from tests.TestSuperList import TestSuperList from tests.TestPreprocessor import TestPreprocessor from tests.TestMatrix import TestMatrix from tests.TestMetrics import TestMetrics from tests.TestProgress import TestProgress from tests.TestAnalysis impo...
{"/tests/__init__.py": ["/tests/TestLM.py", "/tests/TestSuperList.py", "/tests/TestPreprocessor.py", "/tests/TestMatrix.py", "/tests/TestMetrics.py", "/tests/TestProgress.py", "/tests/TestAnalysis.py", "/tests/TestEvaluation.py"]}
6,116
gr33ndata/irlib
refs/heads/master
/tests/TestPreprocessor.py
from unittest import TestCase from irlib.preprocessor import Preprocessor, my_nltk class TestPreprocessor(TestCase): def setUp(self): pass def test_term2ch(self): p = Preprocessor() charlist = p.term2ch('help') self.assertEqual(charlist, ['h', 'e', 'l', 'p']) de...
{"/tests/__init__.py": ["/tests/TestLM.py", "/tests/TestSuperList.py", "/tests/TestPreprocessor.py", "/tests/TestMatrix.py", "/tests/TestMetrics.py", "/tests/TestProgress.py", "/tests/TestAnalysis.py", "/tests/TestEvaluation.py"]}
6,117
gr33ndata/irlib
refs/heads/master
/setup.py
from distutils.core import setup setup( name='irlib', version='0.1.1', author='Tarek Amr', author_email='gr33ndata@yahoo.com', url='https://github.com/gr33ndata/irlib', packages=['irlib'], license='LICENSE.txt', description='Inforamtion Retrieval Library', long_description=open('README.rst').read() )
{"/tests/__init__.py": ["/tests/TestLM.py", "/tests/TestSuperList.py", "/tests/TestPreprocessor.py", "/tests/TestMatrix.py", "/tests/TestMetrics.py", "/tests/TestProgress.py", "/tests/TestAnalysis.py", "/tests/TestEvaluation.py"]}
6,118
gr33ndata/irlib
refs/heads/master
/tests/TestEvaluation.py
from unittest import TestCase from irlib.evaluation import Evaluation class TestEvaluation(TestCase): def setUp(self): pass def test_correct_label_list(self): e = Evaluation() e.ev('Apples', 'Oranges') e.ev('Melons', 'Bananas') expected_labels = ['Apples', 'Oranges', ...
{"/tests/__init__.py": ["/tests/TestLM.py", "/tests/TestSuperList.py", "/tests/TestPreprocessor.py", "/tests/TestMatrix.py", "/tests/TestMetrics.py", "/tests/TestProgress.py", "/tests/TestAnalysis.py", "/tests/TestEvaluation.py"]}
6,119
gr33ndata/irlib
refs/heads/master
/examples/turing chat/qa.py
# Using IR to answer your question # Not so smart question and answer system import os, sys import random # Adding this to path to be able to import irlib sys.path.append('../../') from irlib.preprocessor import Preprocessor from irlib.matrix import Matrix from irlib.metrics import Metrics #qa_list = {'id':{'q': 'q...
{"/tests/__init__.py": ["/tests/TestLM.py", "/tests/TestSuperList.py", "/tests/TestPreprocessor.py", "/tests/TestMatrix.py", "/tests/TestMetrics.py", "/tests/TestProgress.py", "/tests/TestAnalysis.py", "/tests/TestEvaluation.py"]}
6,122
DinarKH/WebServerFlask
refs/heads/master
/WebServerFlask/__init__.py
from flask import Flask from flask_sqlalchemy import SQLAlchemy from flask_bcrypt import Bcrypt from flask_login import LoginManager import redis app = Flask(__name__) POSTGRES_URL = "192.168.99.100:5432" POSTGRES_USER = "postgresuser" POSTGRES_PW = "123456" POSTGRES_DB = "servdb" REDIS_HOST = '127.0.0.1' REDIS_PORT ...
{"/WebServerFlask/routes.py": ["/WebServerFlask/__init__.py"]}
6,123
DinarKH/WebServerFlask
refs/heads/master
/WebServerFlask/routes.py
from flask import render_template, url_for, redirect, flash, request from .forms import RegistationForm, LoginForm, PostForm from .models import User from WebServerFlask import app, bcrypt, db, r_client, REDIS_SET, REDIS_POST_TTL from flask_login import login_user, current_user, logout_user, login_required import datet...
{"/WebServerFlask/routes.py": ["/WebServerFlask/__init__.py"]}
6,137
mantasarul/Search-Validation
refs/heads/main
/search_app/views.py
from django.http.response import HttpResponseRedirect from django.views.generic.base import TemplateView from search_app.models import Index from search_app.forms import IndexForm from django.shortcuts import render from django.views import View from django.views.generic.edit import CreateView, FormView # Create your ...
{"/search_app/views.py": ["/search_app/models.py", "/search_app/forms.py"], "/search_app/forms.py": ["/search_app/models.py"], "/search_app/admin.py": ["/search_app/models.py"]}
6,138
mantasarul/Search-Validation
refs/heads/main
/search_app/urls.py
from django import views from django.urls import path from . import views urlpatterns = [ path('', views.SearchView.as_view(), name='search_url'), path('thank-you', views.ThankYouView.as_view()), path('error.html', views.ErrorView.as_view()), ]
{"/search_app/views.py": ["/search_app/models.py", "/search_app/forms.py"], "/search_app/forms.py": ["/search_app/models.py"], "/search_app/admin.py": ["/search_app/models.py"]}
6,139
mantasarul/Search-Validation
refs/heads/main
/search_app/forms.py
from django.forms import fields from search_app.models import Index from django import forms class IndexForm(forms.ModelForm): class Meta: model = Index fields = '__all__' labels = { 'title': 'Title', 'link': 'Links', } """ class IndexForm(forms.Form): ...
{"/search_app/views.py": ["/search_app/models.py", "/search_app/forms.py"], "/search_app/forms.py": ["/search_app/models.py"], "/search_app/admin.py": ["/search_app/models.py"]}
6,140
mantasarul/Search-Validation
refs/heads/main
/search_app/admin.py
from django.contrib import admin from .models import Index # Register your models here. class IndexAdmin(admin.ModelAdmin): list_display = ('title', 'link') class Meta: verbose_name_plural = 'Index' admin.site.register(Index, IndexAdmin)
{"/search_app/views.py": ["/search_app/models.py", "/search_app/forms.py"], "/search_app/forms.py": ["/search_app/models.py"], "/search_app/admin.py": ["/search_app/models.py"]}
6,141
mantasarul/Search-Validation
refs/heads/main
/search_app/models.py
from django.db import models from django.db.models.base import Model # Create your models here. class Index(models.Model): title = models.CharField(max_length=150) link = models.CharField(max_length=200) #id = models.BigAutoField(primary_key=True)
{"/search_app/views.py": ["/search_app/models.py", "/search_app/forms.py"], "/search_app/forms.py": ["/search_app/models.py"], "/search_app/admin.py": ["/search_app/models.py"]}
6,143
debasmitadasgupta/Assignment
refs/heads/master
/mysite/todo/views.py
# todo/views.py # from django.shortcuts import render from rest_framework import viewsets # add this from .serializers import TodoSerializer,BucketSerializer # add this # from .models import Todo # add this # # add this # queryset = Todo.objects.all() # add thi...
{"/mysite/todo/views.py": ["/mysite/todo/serializers.py", "/mysite/todo/models.py"], "/mysite/todo/serializers.py": ["/mysite/todo/models.py"]}
6,144
debasmitadasgupta/Assignment
refs/heads/master
/mysite/todo/models.py
# todo/models.py from django.db import models # Create your models here. class Bucket(models.Model): bucket_name = models.CharField(max_length=100) # add this class Todo(models.Model): title = models.CharField(max_length=120) description = models.TextField() completed = models.BooleanField(default=Fa...
{"/mysite/todo/views.py": ["/mysite/todo/serializers.py", "/mysite/todo/models.py"], "/mysite/todo/serializers.py": ["/mysite/todo/models.py"]}
6,145
debasmitadasgupta/Assignment
refs/heads/master
/mysite/todo/urls.py
from django.urls import path from . import views urlpatterns = [ path('', views.index, name='index'), # path('<int:question_id>/', views.detail, name='detail'), # # ex: /polls/5/results/ # path('<int:question_id>/results/', views.results, name='results'), # ex: /polls/5/vote/ # path('<int:ques...
{"/mysite/todo/views.py": ["/mysite/todo/serializers.py", "/mysite/todo/models.py"], "/mysite/todo/serializers.py": ["/mysite/todo/models.py"]}
6,146
debasmitadasgupta/Assignment
refs/heads/master
/mysite/polls/views.py
from django.shortcuts import render from .models import Question # Create your views here. from django.http import HttpResponse def index(request): return HttpResponse("Hello, world. You're at the polls index.") def detail(request, question_id): return HttpResponse("You're looking at question %s." % questi...
{"/mysite/todo/views.py": ["/mysite/todo/serializers.py", "/mysite/todo/models.py"], "/mysite/todo/serializers.py": ["/mysite/todo/models.py"]}
6,147
debasmitadasgupta/Assignment
refs/heads/master
/mysite/todo/serializers.py
# todo/serializers.py from rest_framework import serializers from .models import Todo,Bucket class TodoSerializer(serializers.ModelSerializer): class Meta: model = Todo fields = ['id', 'title', 'description', 'completed','bucket_id'] class BucketSerializer(serializers.ModelSerializer): class Meta:...
{"/mysite/todo/views.py": ["/mysite/todo/serializers.py", "/mysite/todo/models.py"], "/mysite/todo/serializers.py": ["/mysite/todo/models.py"]}
6,150
aclifford3/eq-deeps-parser
refs/heads/master
/eq_deeps_parser.py
""" This class uses a log puller to read new combat logs every second. It keeps track of character performances for each fight. """ import configparser import logging import re import time import visualize from log_puller import LogPuller logging.basicConfig(format='%(asctime)s %(levelname)s %(message)s', datefmt='...
{"/eq_deeps_parser.py": ["/visualize.py", "/log_puller.py"], "/test_eq_deeps_parser.py": ["/eq_deeps_parser.py"]}
6,151
aclifford3/eq-deeps-parser
refs/heads/master
/test_eq_deeps_parser.py
'''Tests for eq_deeps_parser.py''' import unittest import eq_deeps_parser class TestEqDeepsParser(unittest.TestCase): '''Tests for eq_deeps_parser.py''' def test_get_contribution_from_melee_dmg_log(self): '''Get a contribution when combat log is a damage dealt event''' log = '[Tue Jul 21 05:1...
{"/eq_deeps_parser.py": ["/visualize.py", "/log_puller.py"], "/test_eq_deeps_parser.py": ["/eq_deeps_parser.py"]}
6,152
aclifford3/eq-deeps-parser
refs/heads/master
/visualize.py
'''Creates visualizations of fight reports''' import logging import matplotlib.pyplot as plt import pandas as pd def plot(fight_report): '''Plots fight report on a horizontal bar graph''' if len(fight_report.contribution_aggregates.keys()) > 0: data = [] index = [] for participant in ...
{"/eq_deeps_parser.py": ["/visualize.py", "/log_puller.py"], "/test_eq_deeps_parser.py": ["/eq_deeps_parser.py"]}
6,153
aclifford3/eq-deeps-parser
refs/heads/master
/log_puller.py
import csv import logging """ This class pulls logs from a log file. It is given a file path and starts reading from the end of the log file. """ def get_starting_line(path): with open(path) as log_file: csv_reader = csv.reader(log_file) log_lines = 0 for row in csv_reader: l...
{"/eq_deeps_parser.py": ["/visualize.py", "/log_puller.py"], "/test_eq_deeps_parser.py": ["/eq_deeps_parser.py"]}
6,193
DevanshSoni/RESTAPI_USING_Django
refs/heads/master
/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/migrations/0005_auto_20190806_1216.py
# Generated by Django 2.2.3 on 2019-08-06 06:46 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('webapp', '0004_auto_20190806_1215'), ] operations = [ migrations.RemoveField( model_name='user', name=...
{"/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py"], "/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py", "/REST_api_UsingDjango/tech_youth_api/te...
6,194
DevanshSoni/RESTAPI_USING_Django
refs/heads/master
/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/migrations/0006_auto_20190806_2208.py
# Generated by Django 2.2.3 on 2019-08-06 16:38 from django.db import migrations, models import django.db.models.deletion import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ('webapp', '0005_auto_20190806_1216'), ] operations = [ migrations...
{"/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py"], "/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py", "/REST_api_UsingDjango/tech_youth_api/te...
6,195
DevanshSoni/RESTAPI_USING_Django
refs/heads/master
/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py
from django.db import models # import datetime from .userModel import * class interest(models.Model): temp_id=models.ForeignKey(to=user,max_length=40,on_delete=models.PROTECT) InterestArea=models.CharField(max_length=40) def __str__(self): return f"{self.InterestArea}"
{"/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py"], "/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py", "/REST_api_UsingDjango/tech_youth_api/te...
6,196
DevanshSoni/RESTAPI_USING_Django
refs/heads/master
/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py
from django.contrib import admin # from . models import * from . interestModel import interest from . userModel import user # Register your models here. admin.site.register(user) admin.site.register(interest) # admin.site.register(questions)
{"/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py"], "/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py", "/REST_api_UsingDjango/tech_youth_api/te...
6,197
DevanshSoni/RESTAPI_USING_Django
refs/heads/master
/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py
from django.db import models # import datetime from . interestModel import * # Create your models here. class user(models.Model): user_id=models.AutoField(primary_key=True,max_length=40) username=models.CharField(max_length=40) emailid=models.CharField(unique=True,max_length=40) password=models....
{"/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py"], "/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py", "/REST_api_UsingDjango/tech_youth_api/te...
6,198
DevanshSoni/RESTAPI_USING_Django
refs/heads/master
/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/migrations/0004_auto_20190806_1215.py
# Generated by Django 2.2.3 on 2019-08-06 06:45 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('webapp', '0003_auto_20190806_1213'), ] operations = [ migrations.AlterField( model_name='user', name='...
{"/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py"], "/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py", "/REST_api_UsingDjango/tech_youth_api/te...
6,199
DevanshSoni/RESTAPI_USING_Django
refs/heads/master
/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/migrations/0003_auto_20190806_1213.py
# Generated by Django 2.2.3 on 2019-08-06 06:43 from django.db import migrations, models import django.utils.timezone class Migration(migrations.Migration): dependencies = [ ('webapp', '0002_questions_time_and_date'), ] operations = [ migrations.RenameField( mo...
{"/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/userModel.py"], "/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/admin.py": ["/REST_api_UsingDjango/tech_youth_api/techAPI/webapp/interestModel.py", "/REST_api_UsingDjango/tech_youth_api/te...
6,201
Julien-V/P5
refs/heads/master
/main.py
#!/usr/bin/python3 # coding : utf-8 from openff import core def main(debug=False): app = core.App(debug) app.run() if __name__ == "__main__": main(False)
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,202
Julien-V/P5
refs/heads/master
/init_db.py
#!/usr/bin/python3 # coding : utf-8 import json import requests import config as cfg from openff.controllers import product, category class Populate: """This class gets all the products in a category and insert them in database """ def __init__(self, param, db, cat_id): """This method initi...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,203
Julien-V/P5
refs/heads/master
/openff/core.py
#!/usr/bin/python3 # coding : utf-8 import init_db from openff.models import db from openff.models import req_sql import config as cfg from openff.controllers import product class App: """Main Class : controllers, views and models used by this class >>> app = core.App() >>> app.run() or with debug...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,204
Julien-V/P5
refs/heads/master
/openff/views/menu_models.py
#!/usr/bin/python3 # coding : utf-8 from openff.views import menu_component as menu_c class ChoiceList: """This class gathers multiples components from openff.views.menu_component in order to create and display a view. This view display a list and an input to get user's anwser. Title, some lines befo...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,205
Julien-V/P5
refs/heads/master
/openff/views/menu.py
#!/usr/bin/python3 # coding : utf-8 import os import shutil class MenuItem: """This class is the parent class of menu_component class""" def __init__(self, indent=1): """This method initializes the class :param indent: set by default to 1 """ self.geometry = shutil.get_termina...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,206
Julien-V/P5
refs/heads/master
/openff/models/db.py
#!/usr/bin/python3 # coding : utf-8 import os import getpass import mysql.connector as mysql_c # from mysql.connector import errorcode import config as cfg class DB: """This class connects or creates a MySQL database.""" def __init__(self): """This method initializes the class and call self.connect(...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,207
Julien-V/P5
refs/heads/master
/openff/models/req_sql.py
#!/usr/bin/python3 # coding : utf-8 # SQL ######################### sql = dict() sql["test"] = "SELECT * from Categories" sql["insert_cat"] = ( """INSERT INTO Categories """ """(category_name) VALUES (%s)""") sql["insert_PiC"] = ( """INSERT INTO Prod_in_Cat """ """(category_id, product_id) VALUES (%...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,208
Julien-V/P5
refs/heads/master
/openff/views/menu_component.py
#!/usr/bin/python3 # coding : utf-8 from . import menu class Title(menu.MenuItem): def __init__(self, text, indent=1): super().__init__(indent) self.text = text self.gen() def gen(self): B = self.colors["bold"] end = self.colors["endc"] # \n self.text \n ...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,209
Julien-V/P5
refs/heads/master
/openff/controllers/product.py
#!/usr/bin/python3 # coding : utf-8 from datetime import datetime from openff.models import req_sql import config as cfg class Product: """This class represents a product, control and insert its caracteristics into database """ def __init__(self, model, category_id): """This method initializ...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,210
Julien-V/P5
refs/heads/master
/openff/controllers/controller.py
#!/usr/bin/python3 # coding : utf-8 import os import config as cfg class Controller: """This class controls the validity of user's anwser""" def __init__(self, view, model): """This method initializes the class :param view: a view (openff.views.menu_models) :param model: a model, dat...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,211
Julien-V/P5
refs/heads/master
/openff/controllers/category.py
#!/usr/bin/python3 # coding : utf-8 from openff.models import req_sql class Category: """This class represents a category, control and insert it into database """ def __init__(self, name, model): """This method initializes the class :param name: category name :param model: cur...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,212
Julien-V/P5
refs/heads/master
/config.py
#!/usr/bin/python3 # coding : utf-8 import getpass from openff.models import req_sql # from openff.views import menu from openff.views import menu_models as mm from openff.controllers import controller as ctrl locale = "fr" title = "Projet 5" back = '777' exit = '999' # DB ######################### db = dict() ...
{"/init_db.py": ["/config.py"], "/openff/core.py": ["/init_db.py", "/config.py"], "/openff/models/db.py": ["/config.py"], "/openff/controllers/product.py": ["/config.py"], "/openff/controllers/controller.py": ["/config.py"]}
6,262
LucienXian/NBA_search_engine
refs/heads/master
/search/views.py
from django.http import HttpResponse from django.http import JsonResponse from django.shortcuts import render from elasticsearch import Elasticsearch from search.elasticsearch import ElasticSearchClass import datetime # Create your views here. try: from django.utils import simplejson as json except Imp...
{"/search/views.py": ["/search/elasticsearch.py"], "/data/views.py": ["/search/elasticsearch.py"]}
6,263
LucienXian/NBA_search_engine
refs/heads/master
/data/views.py
from django.http import HttpResponse from elasticsearch import Elasticsearch import es_client from elasticsearch import helpers from search.elasticsearch import ElasticSearchClass import xlrd # Create your views here. TEAM_DIC = {'ATL':'老鹰','BKN':'篮网','BOS':'凯尔特人','CHI':'公牛','CHA':'黄蜂','CLE':'骑士','MIA':'热火...
{"/search/views.py": ["/search/elasticsearch.py"], "/data/views.py": ["/search/elasticsearch.py"]}
6,264
LucienXian/NBA_search_engine
refs/heads/master
/search/elasticsearch.py
from elasticsearch import Elasticsearch from elasticsearch import helpers import datetime import time abstract_length = 40 def toShortName(name): short_name = name[-5:-1] if short_name == '凯尔特人' : return short_name short_name = name[-4:-1] if short_name in ['76人','步行者','独行侠','森林狼']...
{"/search/views.py": ["/search/elasticsearch.py"], "/data/views.py": ["/search/elasticsearch.py"]}
6,265
pravallika-ganji/bloggy
refs/heads/master
/blog/urls.py
from blog.views import * from django.urls import path from django.contrib.auth import views as v urlpatterns = [ path('',home,name="home"), path('article/<int:pk>',ArticleView.as_view(), name = "detail"), path('createpost/',PostCreate.as_view(),name="create"), path('postupdate/<int:m>',PostUpda...
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,266
pravallika-ganji/bloggy
refs/heads/master
/blog/models.py
from django.db import models from django.contrib.auth.models import User from django.urls import reverse class Category(models.Model): name = models.CharField(max_length=200) def __str__(self): return self.name def get_absolute_url(self): return reverse('home') class Prof...
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,267
pravallika-ganji/bloggy
refs/heads/master
/blog/forms.py
from blog.models import * from django import forms from django.contrib.auth.models import User choices = Category.objects.all().values_list('name','name') choice_list = [] for i in choices: choice_list.append(i) class PostForm(forms.ModelForm): class Meta: model = Post fields = ["title","categ...
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,268
pravallika-ganji/bloggy
refs/heads/master
/blog/views.py
from django.shortcuts import render,redirect,get_object_or_404 from blog.models import * from django.views.generic import View, TemplateView, CreateView, FormView, DetailView, ListView from .forms import * from django.contrib import messages from django.contrib.auth import authenticate, login, logout from django....
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,269
pravallika-ganji/bloggy
refs/heads/master
/blog/admin.py
from django.contrib import admin from .models import Post,Category,Profile,Comment # Register your models here. admin.site.register(Post) admin.site.register(Category) admin.site.register(Profile) admin.site.register(Comment)
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,270
pravallika-ganji/bloggy
refs/heads/master
/bloggers/urls.py
from bloggers.views import * from django.urls import path from django.contrib.auth import views as auth_views urlpatterns = [ path('register/',UserRegisterView.as_view(),name = "register"), path('editprofile/',UserEditView.as_view(),name = "editprofile"), path('pwd/',PasswordsChangeView....
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,271
pravallika-ganji/bloggy
refs/heads/master
/bloggers/views.py
from django.shortcuts import render,HttpResponseRedirect,redirect,get_object_or_404,reverse from django.views import generic from django.views.generic import DetailView,UpdateView,CreateView from django.contrib.auth.forms import UserCreationForm,UserChangeForm from django.urls import reverse_lazy from .forms impo...
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,272
pravallika-ganji/bloggy
refs/heads/master
/bloggers/forms.py
from blog.models import * from django import forms from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm,PasswordChangeForm,UserChangeForm class RegisterForm(UserCreationForm): password1 = forms.CharField(max_length=100,widget=forms.PasswordInput(attrs={'class':'...
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,273
pravallika-ganji/bloggy
refs/heads/master
/bloggers/apps.py
from django.apps import AppConfig class BloggersConfig(AppConfig): default_auto_field = 'django.db.models.BigAutoField' name = 'bloggers'
{"/blog/urls.py": ["/blog/views.py"], "/blog/forms.py": ["/blog/models.py"], "/blog/views.py": ["/blog/models.py", "/blog/forms.py"], "/blog/admin.py": ["/blog/models.py"], "/bloggers/urls.py": ["/bloggers/views.py"], "/bloggers/views.py": ["/bloggers/forms.py", "/blog/models.py", "/blog/forms.py"], "/bloggers/forms.py...
6,274
Lugiax/AutomaticControl
refs/heads/master
/Subrutinas.py
# -*- coding: utf-8 -*- """ Created on Thu Jan 14 22:11:43 2016 @author: root """ from __future__ import division import numpy as np import random as rnd import matplotlib.pyplot as plt ############################################################################### def Perturbaciones(rango,dt=0.01,n_perts=50,plot=0,t...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,275
Lugiax/AutomaticControl
refs/heads/master
/Main3.py
# -*- coding: utf-8 -*- """ Created on Mon Jan 4 11:24:45 2016 Entrenamiento de la red neuronal con los resultados de Main.py @author: carlos """ from __future__ import division import numpy as np from RN2 import RedNeuronal import matplotlib.pyplot as plt import re from Subrutinas import norm with open('result...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,276
Lugiax/AutomaticControl
refs/heads/master
/RN2.py
# -*- coding: utf-8 -*- """ Created on Wed Dec 23 08:49:02 2015 @author: carlos Se creará la clase de Red Neuronal """ from __future__ import division import numpy as np import numpy.random as rnd from AGmultivar import AG class RedNeuronal(object): def __init__(self,estructura,datos_de_entrenamiento=None,neurod...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,277
Lugiax/AutomaticControl
refs/heads/master
/columna2.py
# -*- coding: utf-8 -*- """ Created on Thu Oct 15 08:53:04 2015 @author: carlos Modulo que contiene las diferentes clases que componen a una columna de destilación """ from numericos import newton import numpy as np import matplotlib.pyplot as plt ''' Rehervidor Su única alimentación es el líquido que baja del prime...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,278
Lugiax/AutomaticControl
refs/heads/master
/Main.py
# -*- coding: utf-8 -*- """ Created on Mon Dec 7 10:13:00 2015 @author: carlosaranda Genera datos para el entrenamiento de la red neuronal """ from __future__ import division from ModeloReboiler import Reboiler from AGmultivar import AG import numpy as np import time from Subrutinas import Perturbaciones import matp...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,279
Lugiax/AutomaticControl
refs/heads/master
/RN.py
# -*- coding: utf-8 -*- """ Created on Fri Oct 16 18:40:50 2015 @author: carlos """ import numpy as np class RN(object): def __init__(self,deb=False): self.deb=deb ## Parámetros de red: self.bias=-1 ##Matrices extra # self.xelim=[] # self.xenorm=[] # ...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,280
Lugiax/AutomaticControl
refs/heads/master
/ModeloReboiler.py
# -*- coding: utf-8 -*- """ Created on Wed Feb 3 21:08:01 2016 @author: root """ from __future__ import division import numpy import numericos import matplotlib #import matplotlib.pyplot as plt def Reboiler(Controladores,Lvar, mezcla=('C8','C10'),dt=0.01,plot=0,delay=0): ##Base de datos de los compu...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,281
Lugiax/AutomaticControl
refs/heads/master
/Main2.py
# -*- coding: utf-8 -*- """ Created on Mon Dec 14 12:45:43 2015 @author: carlosaranda Prueba final Red Neuronal para control """ import re from columna2 import reboiler from RN2 import RedNeuronal, redimensionarPesos, dimensionarMatricesDePesos import numpy as np from Subrutinas import Perturbaciones, denorm, norm imp...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,282
Lugiax/AutomaticControl
refs/heads/master
/numericos.py
# -*- coding: utf-8 -*- """ Created on Sun Aug 23 19:07:23 2015 Compilación de métodos numéricos @author: carlos """ from __future__ import division def newton(f,x0,it=20,dstep=0.0001): x=x0 for i in range(it): df=(f(x+dstep)-f(x-dstep))/dstep if df==0: break x=x-f(x)/df ...
{"/columna2.py": ["/numericos.py"], "/Main2.py": ["/columna2.py", "/RN2.py", "/Subrutinas.py"]}
6,284
LialinMaxim/Alnicko
refs/heads/master
/test_sender.py
import multiprocessing import time from unittest import TestCase, mock from files_sender import Uploader def mock_file_sender(path_to_file, ): """ Simulator of the loading process :param path_to_file: string :return: (path_to_file, status code, status name) """ time.sleep(.6) if '7' in ...
{"/test_sender.py": ["/files_sender.py"], "/files_sender.py": ["/test_sender.py"]}
6,285
LialinMaxim/Alnicko
refs/heads/master
/files_sender.py
""" Write module to upload some files to the remote server. Uploading should be done in parallel. Python multiprocessing module should be used. Real uploading is not part of this task, use some dummy function for emulate upload. Input data: - List of files to upload - Maximum number of parallel uploading process - Que...
{"/test_sender.py": ["/files_sender.py"], "/files_sender.py": ["/test_sender.py"]}
6,288
vdeleon/clickTwitch
refs/heads/master
/clickTwitch/__init__.py
''' clickTwitch is an automation tool that claims your twitch reward while watching a stream. API: ======== `detectPosition()` `clickPosition()` `randomMovement()` `isLetterY()` ''' import mouse def detectPosition(): ''' Waits until client presses middle button, then parses the mouse position to variabl...
{"/main.py": ["/clickTwitch/__init__.py"]}
6,289
vdeleon/clickTwitch
refs/heads/master
/main.py
import subprocess import clickTwitch from time import sleep # Set up. try: clickInterval = int(input('Set time in seconds the mouse will click (default = 30): ')) if clickInterval <= 1: raise ValueError except ValueError: clickInterval = 30 finally: subprocess.run('cls', shell=True) wantsR...
{"/main.py": ["/clickTwitch/__init__.py"]}
6,295
NURx2/CleaningManager
refs/heads/master
/src/modules/executor.py
from src.database import db class Executor(db.Model): id = db.Column(db.Integer, primary_key=True) name = db.Column(db.String(16)) telegram_id = db.Column(db.String(32)) # db.session.add(my_object)
{"/src/database/additions.py": ["/src/modules/executor.py"], "/main.py": ["/src/parser/parser.py"], "/src/parser/parser.py": ["/src/database/additions.py", "/src/static/constants.py"]}
6,296
NURx2/CleaningManager
refs/heads/master
/src/database/additions.py
from . import db from typing import List from src.modules.executor import Executor def update_executors(names: List[str]): for name in names: executor = Executor(name=name)
{"/src/database/additions.py": ["/src/modules/executor.py"], "/main.py": ["/src/parser/parser.py"], "/src/parser/parser.py": ["/src/database/additions.py", "/src/static/constants.py"]}
6,297
NURx2/CleaningManager
refs/heads/master
/setup.py
from setuptools import setup, find_packages with open("README.md", "r") as fh: long_description = fh.read() setup( name="Cleaning Manager", author="NURx2", description="It allows to track the execution and quality of a cleaning.", long_description=long_description, long_description_content_typ...
{"/src/database/additions.py": ["/src/modules/executor.py"], "/main.py": ["/src/parser/parser.py"], "/src/parser/parser.py": ["/src/database/additions.py", "/src/static/constants.py"]}
6,298
NURx2/CleaningManager
refs/heads/master
/main.py
from flask import Flask from src.database import db from src.parser.parser import parse app = Flask(__name__) # connection string of database app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///data.db' app.config['SQLACLHEMY_TRACK_MODIFICATIONS'] = False db.init_app(app) def main(): parse() if __name__ == '__m...
{"/src/database/additions.py": ["/src/modules/executor.py"], "/main.py": ["/src/parser/parser.py"], "/src/parser/parser.py": ["/src/database/additions.py", "/src/static/constants.py"]}
6,299
NURx2/CleaningManager
refs/heads/master
/src/parser/parser.py
import openpyxl from src.database.additions import update_executors from src.static.constants import cnt_weeks def colored(cell): return True def parse(): table = openpyxl.load_workbook(filename='table.xlsx') main_sheet = table['Лист1'] names = [value.value for value in main_sheet['A'][1:]] upd...
{"/src/database/additions.py": ["/src/modules/executor.py"], "/main.py": ["/src/parser/parser.py"], "/src/parser/parser.py": ["/src/database/additions.py", "/src/static/constants.py"]}
6,300
NURx2/CleaningManager
refs/heads/master
/src/static/constants.py
cnt_weeks = 8
{"/src/database/additions.py": ["/src/modules/executor.py"], "/main.py": ["/src/parser/parser.py"], "/src/parser/parser.py": ["/src/database/additions.py", "/src/static/constants.py"]}
6,303
OpiumSmoke/django-tutorial-todolist
refs/heads/master
/todos/urls.py
from django.urls import path from . import views app_name = 'todos' urlpatterns = [ path('', views.index, name='index'), path('details/<int:id>', views.details, name='detail'), path('add', views.add, name='add'), path('update/<int:id>', views.update, name='update'), path('delete/<int:id>', views....
{"/tools/.pythonrc.py": ["/todos/models.py"], "/tools/populate-test-models.py": ["/todos/models.py"], "/todos/views.py": ["/todos/models.py"]}
6,304
OpiumSmoke/django-tutorial-todolist
refs/heads/master
/tools/.pythonrc.py
import os, sys, importlib from django.test.utils import setup_test_environment setup_test_environment() prj = importlib.__import__(os.environ['DJANGO_SETTINGS_MODULE'].split('.')[0], fromlist=('settings',)) settings = prj.settings app_names = [ app.split('.')[0] for app in settings.INSTALLED_APPS if not app.startswi...
{"/tools/.pythonrc.py": ["/todos/models.py"], "/tools/populate-test-models.py": ["/todos/models.py"], "/todos/views.py": ["/todos/models.py"]}
6,305
OpiumSmoke/django-tutorial-todolist
refs/heads/master
/tools/populate-test-models.py
import os, sys, django def add_test_todos(): print('Populating Todo objects...') if not Todo.objects.filter(title='My 1st Todo'): todo = Todo(title='My 1st Todo', text='Reading...') todo.save() if not Todo.objects.filter(title='My 2nd Todo'): todo = Todo(title='My 2nd Todo', text='...
{"/tools/.pythonrc.py": ["/todos/models.py"], "/tools/populate-test-models.py": ["/todos/models.py"], "/todos/views.py": ["/todos/models.py"]}
6,306
OpiumSmoke/django-tutorial-todolist
refs/heads/master
/todos/views.py
from django.shortcuts import render, redirect, get_object_or_404 from django.urls import reverse from django.contrib import messages # from django.http import HttpResponse from .models import Todo, Category def index(request): todos = Todo.objects.all()[:10] context = { 'todos':todos } retu...
{"/tools/.pythonrc.py": ["/todos/models.py"], "/tools/populate-test-models.py": ["/todos/models.py"], "/todos/views.py": ["/todos/models.py"]}
6,307
OpiumSmoke/django-tutorial-todolist
refs/heads/master
/todos/models.py
from django.db import models from django.utils import timezone class Todo(models.Model): title = models.CharField(max_length=200) text = models.TextField() created_at = models.DateTimeField(default=timezone.now, blank=True) def __str__(self): return '%s: %s' % (self.id, self.title) class Cate...
{"/tools/.pythonrc.py": ["/todos/models.py"], "/tools/populate-test-models.py": ["/todos/models.py"], "/todos/views.py": ["/todos/models.py"]}
6,312
eltondornelas/django-semana-dev-python-treinaweb
refs/heads/master
/gerenciador_tarefas/urls.py
"""gerenciador_tarefas URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.2/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home')...
{"/app/services/task_service.py": ["/app/models.py"], "/app/urls.py": ["/app/views/task_views.py"]}
6,313
eltondornelas/django-semana-dev-python-treinaweb
refs/heads/master
/app/views/task_views.py
from django.contrib.auth.decorators import login_required from django.http import HttpResponse from django.shortcuts import render, redirect from ..forms import TaskForm from app.entities.task import Task from ..services import task_service # com o @login_required é um decorator que verifica se usuário esta logado # ...
{"/app/services/task_service.py": ["/app/models.py"], "/app/urls.py": ["/app/views/task_views.py"]}
6,314
eltondornelas/django-semana-dev-python-treinaweb
refs/heads/master
/app/models.py
from django.db import models from django.contrib.auth.models import User class Task(models.Model): PRIORITY_CHOICES = [ ('H', 'High'), ('N', 'Normal'), ('L', 'Low') ] title = models.CharField(max_length=30, null=False, blank=False) description = models.CharField(max_length=100...
{"/app/services/task_service.py": ["/app/models.py"], "/app/urls.py": ["/app/views/task_views.py"]}
6,315
eltondornelas/django-semana-dev-python-treinaweb
refs/heads/master
/app/templatetags/my_filters.py
from django import template register = template.Library() @register.filter(name='add_class') def add_class(value, arg): return value.as_widget(attrs={'class': arg}) # recebe um input e a classe; # depois adiciona nesse input a classe # form_task.title é o input nesse caso
{"/app/services/task_service.py": ["/app/models.py"], "/app/urls.py": ["/app/views/task_views.py"]}
6,316
eltondornelas/django-semana-dev-python-treinaweb
refs/heads/master
/app/services/task_service.py
from app.models import Task def register_task(task): Task.objects.create(title=task.title, description=task.description, expiration_date=task.expiration_date, priority=task.priority, user=task.user) def task_list(user): return Task.objects.filter(user=user).al...
{"/app/services/task_service.py": ["/app/models.py"], "/app/urls.py": ["/app/views/task_views.py"]}
6,317
eltondornelas/django-semana-dev-python-treinaweb
refs/heads/master
/app/urls.py
from django.urls import path from .views.task_views import * from .views.user_views import * urlpatterns = [ path('task_list/', task_list, name='task_list_route'), path('register_task/', register_task, name='register_task_route'), path('edit_task/<int:id>', edit_task, name='edit_task_route'), path('rem...
{"/app/services/task_service.py": ["/app/models.py"], "/app/urls.py": ["/app/views/task_views.py"]}
6,318
jowr/jopy
refs/heads/master
/jopy/styles/__init__.py
import matplotlib.pyplot as plt try: from .plots import Figure except: from jopy.styles.plots import Figure def get_figure(orientation='landscape',width=110,fig=None,axs=False): """Creates a figure with some initial properties The object can be customised with the parameters. But since it is an...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,319
jowr/jopy
refs/heads/master
/jopy/recip/__init__.py
# -*- coding: utf-8 -*- from __future__ import print_function, division if __name__ == "__main__": from jopy.recip.mechanisms import RecipExplicit, RecipImplicit #from math import pi import numpy as np import matplotlib.pyplot as plt me = RecipImplicit() metoo = RecipExplicit() cr ...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,320
jowr/jopy
refs/heads/master
/jopy/styles/mplib.py
# -*- coding: utf-8 -*- from __future__ import print_function, division from ..base import JopyBaseClass import matplotlib as mpl import matplotlib.cm as mplcm import numpy as np from matplotlib.colors import LinearSegmentedColormap import brewer2mpl from itertools import cycle import sys import platform class Base...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,321
jowr/jopy
refs/heads/master
/jopy/data/sources.py
# -*- coding: utf-8 -*- from __future__ import print_function, division import os from blaze.interactive import Data def get_sqlite_handle(path): """Gets a blaze object for an sqlite database Does not simplify things, but helps me remember to use blaze more Parameters ---------- path : str ...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,322
jowr/jopy
refs/heads/master
/jopy/styles/plots.py
# -*- coding: utf-8 -*- from __future__ import print_function, division import matplotlib import matplotlib.pyplot as plt import copy class Figure(matplotlib.figure.Figure): def _get_axis(self,**kwargs): ax = kwargs.pop('ax', self._get_axes()[0]) return ax def _get_axes(self,**k...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,323
jowr/jopy
refs/heads/master
/test/test_thermo/__init__.py
# -*- coding: utf-8 -*- from __future__ import print_function, division import jopy.thermo class TestUtils(object): @classmethod def setup_class(cls): pass def test_lmtd(self): res = jopy.thermo.lmtd(0.0, 0.0) assert res == 0.0 res = jopy.thermo.lmtd(10.0, 10.0) p...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,324
jowr/jopy
refs/heads/master
/jopy/thermo/utils.py
# -*- coding: utf-8 -*- from __future__ import print_function, division import numpy as np import warnings class UnitError(ValueError): pass def check_T(T): """Check for valid temperature Parameters ---------- T : float or numpy.array in Kelvin [K] Returns ------- bo...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,325
jowr/jopy
refs/heads/master
/jopy/utils.py
# -*- coding: utf-8 -*- from __future__ import print_function, division import numpy as np from numpy import pi,e def module_class_dict(mod): """Get all classes from a module in a dict with the names Parameters ---------- mod : Python module The module to extract the classes from. ...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,326
jowr/jopy
refs/heads/master
/jopy/thermo/__init__.py
# -*- coding: utf-8 -*- from __future__ import print_function, division import matplotlib.pyplot as plt import numpy as np from ..utils import transition_factor from .utils import check_T def eta_carnot(T_cold,T_hot): check_T(T_cold) check_T(T_hot) return 1. - T_cold / T_hot def __lmtd(Delta_T1, De...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,327
jowr/jopy
refs/heads/master
/jopy/base.py
# -*- coding: utf-8 -*- from __future__ import print_function, division class JopyBaseClass(object): """The base class for all objects The mother of all classes in the jopy module. Implements basic functionality for debugging and exception handling. Extended description of function, just a u...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,328
jowr/jopy
refs/heads/master
/dev/builder.py
import jinja2 import os import requests import json from distutils.version import LooseVersion #, StrictVersion import codecs import datetime from jinja2.environment import Environment import subprocess import sys #import conda_api #import sys template_dir = os.path.dirname(os.path.abspath(__file__)) target_dir = os....
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,329
jowr/jopy
refs/heads/master
/test/test_jopy.py
# -*- coding: utf-8 -*- from __future__ import print_function, division from matplotlib.figure import Figure from jopy.recip.mechanisms import RecipExplicit, RecipImplicit, RecipBase import numpy as np from jopy.styles.mplib import BaseStyle, DtuStyle, IpuStyle from jopy.utils import module_class_dict import jopy.st...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,330
jowr/jopy
refs/heads/master
/jopy/recip/mechanisms.py
# -*- coding: utf-8 -*- from __future__ import print_function, division from ..base import JopyBaseClass import numpy as np from numpy import pi from texttable import Texttable from scipy.optimize import minimize, minimize_scalar from abc import ABCMeta, abstractmethod class RecipBase(JopyBaseClass): """ The...
{"/jopy/styles/__init__.py": ["/jopy/styles/plots.py", "/jopy/utils.py", "/jopy/styles/mplib.py"], "/jopy/recip/__init__.py": ["/jopy/recip/mechanisms.py"], "/jopy/styles/mplib.py": ["/jopy/base.py"], "/test/test_thermo/__init__.py": ["/jopy/thermo/__init__.py"], "/jopy/thermo/__init__.py": ["/jopy/utils.py", "/jopy/th...
6,334
sbxg/sbxg
refs/heads/master
/sbxg/subcomponent.py
# Copyright (c) 2017 Jean Guyomarc'h # # 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 use, copy, modify, merge, publish, dis...
{"/sbxg/__main__.py": ["/sbxg/utils.py"]}
6,335
sbxg/sbxg
refs/heads/master
/tests/test_boostrap.py
# Copyright (c) 2017 Jean Guyomarc'h # # 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 use, copy, modify, merge, publish, dis...
{"/sbxg/__main__.py": ["/sbxg/utils.py"]}
6,336
sbxg/sbxg
refs/heads/master
/sbxg/utils.py
# Copyright (c) 2017 Jean Guyomarc'h # # 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 use, copy, modify, merge, publish, dis...
{"/sbxg/__main__.py": ["/sbxg/utils.py"]}