コード例 #1
0
def runexp_schedulability_LAG(input=Input_guan,iname=input.__name__):
    # setsettaskset: a set of sets of task sets, each set has the same utot    
    setsettaskset, processor, xaxis = input()
    solutions = [LAG.LAG_nopt_solution]
    solnames=["lag"]
    strtime = time.strftime("%m%dT%H%M",time.localtime(time.time()))

    with open("./result_sched_%s_%s.out" % (iname, strtime), 'w') as f:
        plt.figure(1)
        plt.subplot(111)
        plt.tick_params(labelsize=12)
        colors=['r','b','g','y','k']
        markers=['s','^','x','*','.']
        for sol in solutions:
            solname = f"{sol.__name__}"
            f.write(solname+'\n')
            print(solname)
            acrates = []
            for settaskset in setsettaskset:          #settaskset: a set of task sets
                acnum = 0
                for taskset in settaskset:            #taskset: a task set
                    if (LAG.LAG_Analysis(taskset,processor,sol)):
                        acnum += 1
                utot = sum([task.e/task.p for task in settaskset[0]]) 
                acrate = acnum / len(settaskset)    
                index = setsettaskset.index(settaskset)
                strresult= "%.2f %.2f %.3f" % (xaxis[index], utot, acrate)
                acrates.append(acrate)
                print(strresult)
                f.write(strresult+'\n')

            i = solutions.index(sol) % len(colors)
            plt.plot(xaxis, acrates, color=colors[i+2], linestyle="-", marker=markers[i+2], linewidth=1.0, label=solnames[i])
            plt.xticks(xaxis,xaxis)
コード例 #2
0
ファイル: ki1.5.py プロジェクト: natsukaze4545/nnnn
#MK:RENT BOT v10.0.0
# -*- coding: utf-8 -*-
import LAG
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAPI.main import qr
from threading import Thread
import time,random,sys,re,os,json,subprocess,codecs,threading,glob,requests,string,ast
##############################################
cl = LAG.LINE()
try:
    f=open('cl8.csv','r')
    token=f.read()
    cl.login(token=token)
    f.close()
except:
    cl.login(token=qr().get())
    f=open('cl8.csv','w')
    f.write(cl.authToken)
    f.close()
##############################################
k1 = LAG.LINE()
k1.login(token="EuqyhHGgNxkRyK6RuMib.A2FDe2nvqKuQc80dP+Qq6W.71x8lSSeb6CTD9g+GBgruNIG4cc6zpVLVy3aRO0NCeI=")
##############################################
cl.loginResult()
print cl.getUserTicket()
##############################################
reload(sys)
sys.setdefaultencoding('utf-8')
コード例 #3
0
#SRSU LINE SELF BOT v7.0.3
# -*- coding: utf-8 -*-
import LAG
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAPI.main import qr
from threading import Thread
import time,random,sys,re,os,json,subprocess,codecs,threading,glob,requests,string
##############################################
cl = LAG.LINE()
cl.login(token=qr().get())
cl.loginResult()
##############################################
reload(sys)
sys.setdefaultencoding('utf-8')
##############################################
help ="""SRSU FUNNY BOT HELP
help ...ヘルプを送信します
nk: ...名前で蹴ります
speed ...処理速度を送信します
kickall ...破壊します!
gurl ...グルのURLを送信します
srsu.weebly.com"""
##############################################
def bot(op):
    try:
        if op.type == 0:
            return
        if op.type == 25:
コード例 #4
0
ファイル: TOKEN.py プロジェクト: natsukaze4545/nnnn
#SRSU LINE BOT TOKEN GENERATOR v7.0.3
import LAG
from LAPI.main import qr
c = LAG.LINE()
c.login(token=qr().get())
print("Auth token : " + c.authToken)
コード例 #5
0
ファイル: kicker.py プロジェクト: natsukaze4545/nnnn
#SRSU LINE KICKER BOT v9.0.2
# -*- coding: utf-8 -*-
import LAG
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAPI.main import qr
from threading import Thread
import time,random,sys,re,os,json,subprocess,codecs,threading,glob,requests,string,ast
##############################################
cl = LAG.LINE()
cl.login(token=qr().get())
##############################################
k1 = LAG.LINE()
k1.login(token="Er0Xwc7yUPHSjDe5b7Ba.nktOVlxstjXQ7JL0HvpVMG.ruC0hU/zbYHS24/Nn3W0htLpPo4ImuTiKCLCasHsBzo=")
##############################################
k2 = LAG.LINE()
k2.login(token="ErM9EzKB2eXMx1mNdwKe.8duTR3eAdO3VCcwVCVvDVG.tNtHYRbl+q1qA5cOPO9ATxiKnKBpD4RJ0KCdhWFbH6M=")
##############################################
k3 = LAG.LINE()
k3.login(token="ErAFzOkeg0xFOxIqSBV4.Rm04MXNPyrxKCBXzVCH+Ta.MbSQbpmJ8eIB/l0uh+sWNK0AR6ZycIGWm1PXBCD9Xn0=")
##############################################
k4 = LAG.LINE()
k4.login(token="Ere3RcJpHmd97BgvcjV1.DPLuBYhMBUKAgmgenIJWGq.DycQo+7SocPyeMbrcBN5CNbrgf2AAFVsRqvvodJo68g=")
##############################################
k5 = LAG.LINE()
k5.login(token="ErbduPwuYTpzcP0QB8r7.hLkxQqwlVRIMzWaUqoo+DW.J/aKIZZWmEQbdHW5pH9IPbQ9WKxrnKWf0zLFA/Mcrak=")
##############################################
cl.loginResult()
print(cl.getUserTicket())
コード例 #6
0
ファイル: MK.py プロジェクト: natsukaze4545/nnnn
# -*- coding: utf-8 -*-

import LAG
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAG.lib.Gen.ttypes import *
from datetime import datetime
from LAPI.main import qr
from threading import Thread
import time, random, sys, re, os, json, subprocess, codecs, threading, glob, requests, string

acil = LAG.LINE()
acil.login(token=qr().get())
acil.loginResult()
#acil = LAG.LINE()
#acil.login(token="your token here")
#acil.loginResult()

print "ログイン成功!"
reload(sys)
sys.setdefaultencoding('utf-8')

helpMessage = """SRSU BOT v3

※: => :
※/ => /

/help >helpをだす
/version =>アップデート履歴・現在のバージョン

—test