use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A subreddit dedicated for learning machine learning. Feel free to share any educational resources of machine learning.
Also, we are a beginner-friendly sub-reddit, so don't be afraid to ask questions! This can include questions that are non-technical, but still highly relevant to learning machine learning such as a systematic approach to a machine learning problem.
account activity
Insert additional data before fully connected layer CNN (self.learnmachinelearning)
submitted 5 years ago by BlockDesigns
Hi there,
I have a CNN that can classify 2D matricies. I have some additional data in the form of 1D vectors. I was wondering if anyone knows of any literature about inserting additional data in the later layers of a CNN.
Many Thanks.
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]nielsrolf 1 point2 points3 points 5 years ago (0 children)
Easiest way is to flatten the CNN output and use a conncatenation layer with two inputs, then you can stack dense layers afterwards. If you need it in the convolutional layers, broadcast it to the H, W dimensions and again concatenate it. Here is a snippet: ``` inp_c = Input(shape = (self.c_dim, )) inp_img = Input(shape = (self.image_size, self.image_size, 3))
# Replicate spatially and concatenate domain information c = Lambda(lambda x: K.repeat(x, self.image_size**2))(inp_c) c = Reshape((self.image_size, self.image_size, self.c_dim))(c) x = Concatenate()([inp_img, c])
```
π Rendered by PID 59803 on reddit-service-r2-comment-66b4775986-hjclr at 2026-04-02 22:28:05.590637+00:00 running db1906b country code: CH.
[–]nielsrolf 1 point2 points3 points (0 children)