Fix module layer issues

This commit is contained in:
2024-05-30 13:08:13 +02:00
parent 8ac2da004c
commit 479c1119e7
4 changed files with 116 additions and 95 deletions

View File

@@ -17,19 +17,14 @@ class Module : public Layers::SequentialLayer {
int getInputSize();
void addLayer(const std::string& name, Layers::SequentialLayer* layer);
Layers::SequentialLayer* getLayer(const std::string& name);
const std::unordered_map<std::string, Layers::SequentialLayer*>& getLayers() const;
const std::vector<std::pair<std::string, Layers::SequentialLayer*>>& getLayers() const;
protected:
int inputSize;
int inputChannels;
std::vector<std::pair<std::string, Layers::SequentialLayer*>> layers;
int outputSize;
int outputChannels;
std::vector<std::pair<std::string, Layers::SequentialLayer*>> layers;
std::unordered_map<std::string, Layers::SequentialLayer*> layerMap;
int inputSize;
};
} // namespace CUDANet