Skip to content

Commit

Permalink
fixed a minor bug in setting the expression in the scheduler
Browse files Browse the repository at this point in the history
  • Loading branch information
Aynur Adanbekova authored and Aynur Adanbekova committed Sep 16, 2024
1 parent 1be109c commit 4148f48
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
3 changes: 3 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
symbolicai
pytest
rpyc
Empty file added src/__init__.py
Empty file.
2 changes: 1 addition & 1 deletion src/func.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def __init__(self, expr: Expression, num_workers: int, engine: Callable, dataset
self.llm_responses: Dict[int, Optional[Any]] = {}
self.llm_response_ready: Dict[int, threading.Event] = {}
self.pending_tasks: int = len(self.dataset)
self.expr: Expression = expr
self.expr: Expression = expr()
self.pending_tasks_update: threading.Event = threading.Event()

def single_expression(self, data_point: Any) -> Any:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,12 @@

from symai import Expression, Symbol
from symai.backend.base import BatchEngine
from src.func import BatchScheduler
from symai.functional import EngineRepository

import sys
import os
sys.path.insert(0, os.path.abspath(os.path.join(os.path.dirname(__file__), '..')))
from src.func import BatchScheduler

class TestExpression(Expression):
def __init__(self, **kwargs):
Expand Down

0 comments on commit 4148f48

Please sign in to comment.