Skip to content

Commit

Permalink
Update TrInfo
Browse files Browse the repository at this point in the history
  • Loading branch information
elbakramer committed Sep 6, 2022
1 parent 2ce5f1c commit 8b4ac76
Show file tree
Hide file tree
Showing 2 changed files with 620 additions and 430 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def __init__(
tr_code: Optional[str] = None,
name: Optional[str] = None,
tr_name: Optional[str] = None,
tr_names_svr: Optional[str] = None,
tr_name_svr: Optional[str] = None,
tr_type: Optional[str] = None,
gfid: Optional[str] = None,
inputs: Optional[Sequence[Field]] = None,
Expand All @@ -77,7 +77,7 @@ def __init__(
self.tr_code = tr_code
self.name = name
self.tr_name = tr_name
self.tr_names_svr = tr_names_svr
self.tr_name_svr = tr_name_svr
self.tr_type = tr_type
self.gfid = gfid
self.inputs = inputs
Expand All @@ -92,7 +92,7 @@ def __repr__(self):
self.tr_code,
self.name,
self.tr_name,
self.tr_names_svr,
self.tr_name_svr,
self.tr_type,
self.gfid,
self.inputs,
Expand All @@ -108,7 +108,7 @@ def __eq__(self, other):
self.tr_code.lower() == other.tr_code.lower()
and self.name == other.name
and self.tr_name == other.tr_name
and self.tr_names_svr == other.tr_names_svr
and self.tr_name_svr == other.tr_name_svr
and self.tr_type == other.tr_type
and self.gfid == other.gfid
and self.inputs == other.inputs
Expand Down Expand Up @@ -192,7 +192,7 @@ def from_encfile(
multi_outputs_name = ""
multi_outputs = []

tr_names_svr = ""
tr_name_svr = ""
gfid = ""

line = next(lines)
Expand All @@ -202,7 +202,7 @@ def from_encfile(
tr_name = line.split("=", 2)[1]
line = next(lines)
if line.startswith("TRNameSVR="):
tr_names_svr = line.split("=", 2)[1]
tr_name_svr = line.split("=", 2)[1]
line = next(lines)
assert line.startswith("TRType=")
tr_type = line.split("=", 2)[1]
Expand Down Expand Up @@ -260,7 +260,7 @@ def from_encfile(
tr_code,
tr_name_readable,
tr_name,
tr_names_svr,
tr_name_svr,
tr_type,
gfid,
inputs,
Expand Down Expand Up @@ -318,6 +318,7 @@ def infos_from_data_dir(
return results

SINGLE_TO_MULTI_TRCODES = [
"opt10007",
"opt10072",
"opt10073",
"opt10075",
Expand Down
Loading

0 comments on commit 8b4ac76

Please sign in to comment.