Skip to content

Commit

Permalink
Merge pull request #724 from RasmusOrsoe/nodeaspulses-log-stealing
Browse files Browse the repository at this point in the history
Alter logic of default `NodeDefinition` in `GraphDefinition`
  • Loading branch information
RasmusOrsoe committed May 23, 2024
2 parents 90d8259 + ba21461 commit fc5d955
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/graphnet/models/graphs/graph_definition.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class GraphDefinition(Model):
def __init__(
self,
detector: Detector,
node_definition: NodeDefinition = NodesAsPulses(),
node_definition: NodeDefinition = None,
edge_definition: Optional[EdgeDefinition] = None,
input_feature_names: Optional[List[str]] = None,
dtype: Optional[torch.dtype] = torch.float,
Expand Down Expand Up @@ -69,6 +69,9 @@ def __init__(
# Base class constructor
super().__init__(name=__name__, class_name=self.__class__.__name__)

if node_definition is None:
node_definition = NodesAsPulses()

# Member Variables
self._detector = detector
self._edge_definition = edge_definition
Expand Down

0 comments on commit fc5d955

Please sign in to comment.