graphinvent/MolecularGraph.py
def pad_graph_representation(self) -> None:
        """
        Pads arrays to size corresponding to largest graph in training, testing,
        and validation datasets.
        """
        # initialize the padded graph representation arrays
        node_features_padded = np.zeros((self.constants.max_n_nodes,
                                         self.constants.n_node_features))
        edge_features_padded = np.zeros((self.constants.max_n_nodes,
                                         self.constants.max_n_nodes,
                                         self.constants.n_edge_features))

        # pad up to size of largest graph
        node_features_padded[:self.n_nodes, :]                = self.node_features
        edge_features_padded[:self.n_nodes, :self.n_nodes, :] = self.edge_features

        self.node_features = node_features_padded
        self.edge_features = edge_features_padded

        Pads arrays to size corresponding to largest graph in training, testing,
        and validation datasets.
        
Pads arrays to size corresponding to largest graph in training, testing,
and validation datasets.
Pads arrays to size corresponding to largest graph in training testing and validation datasets .
def pad_graph_representation(self) -> None:
        node_features_padded = np.zeros((self.constants.max_n_nodes,
                                         self.constants.n_node_features))
        edge_features_padded = np.zeros((self.constants.max_n_nodes,
                                         self.constants.max_n_nodes,
                                         self.constants.n_edge_features))
        node_features_padded[:self.n_nodes, :]                = self.node_features
        edge_features_padded[:self.n_nodes, :self.n_nodes, :] = self.edge_features
        self.node_features = node_features_padded
        self.edge_features = edge_features_padded
def pad_graph_representation ( self ) -> None : node_features_padded = np . zeros ( ( self . constants . max_n_nodes , self . constants . n_node_features ) ) edge_features_padded = np . zeros ( ( self . constants . max_n_nodes , self . constants . max_n_nodes , self . constants . n_edge_features ) ) node_features_padded [ : self . n_nodes , : ] = self . node_features edge_features_padded [ : self . n_nodes , : self . n_nodes , : ] = self . edge_features self . node_features = node_features_padded self . edge_features = edge_features_padded
Pads arrays to size corresponding to largest graph in training, testing,
and validation datasets.
Pads arrays to size corresponding to largest graph in training testing and validation datasets .
"""
        Pads arrays to size corresponding to largest graph in training, testing,
        and validation datasets.
        """ # initialize the padded graph representation arrays # pad up to size of largest graph
self