You've already forked HeurAMS-Legacy
更新
This commit is contained in:
@@ -3,15 +3,15 @@
|
||||
import heurams.kernel.particles as pt
|
||||
import heurams.services.timer as timer
|
||||
from typing import Tuple
|
||||
from .apparatus import Apparatus
|
||||
|
||||
class Core():
|
||||
"""堆芯: 记忆流程核心状态机"""
|
||||
def __init__(self, atoms: list, stage = ""):
|
||||
class Procession():
|
||||
"""队列: 记忆流程核心状态机"""
|
||||
def __init__(self, atoms: list, phase: str = ""):
|
||||
self.atoms = atoms
|
||||
self.queue = atoms.copy()
|
||||
self.current_atom = atoms[0]
|
||||
self.cursor = 0
|
||||
self.phase = phase
|
||||
|
||||
def forward(self, step = 1):
|
||||
self.cursor += step
|
||||
@@ -21,8 +21,11 @@ class Core():
|
||||
except IndexError:
|
||||
return 0
|
||||
|
||||
def append(self, atom):
|
||||
self.queue.append(self.current_atom)
|
||||
def append(self, atom = None):
|
||||
if atom == None:
|
||||
self.queue.append(self.current_atom)
|
||||
else:
|
||||
self.queue.append(atom)
|
||||
|
||||
def __len__(self):
|
||||
return (len(self.queue) - self.cursor)
|
||||
@@ -32,9 +35,13 @@ class Core():
|
||||
|
||||
class Fission():
|
||||
"""裂变器: 单原子调度展开器"""
|
||||
def __init__(self, atom: pt.Atom):
|
||||
def __init__(self, atom: pt.Atom, stage = ""):
|
||||
self.atom = atom
|
||||
atom.register["orbital"]
|
||||
atom.register["orbital"]["puzzle_config"]
|
||||
|
||||
class Phaser():
|
||||
"""移相器: 全局调度阶段管理器"""
|
||||
|
||||
|
||||
class Reactork():
|
||||
"""反应堆对象, 处理和分配一次文件记忆流程的资源与策略"""
|
||||
|
||||
Reference in New Issue
Block a user