anktplwl91 / visualizing_convnets Goto Github PK
View Code? Open in Web Editor NEWThis is the code repository for my Medium post "Understanding your Convolution network with Visualizations"
This is the code repository for my Medium post "Understanding your Convolution network with Visualizations"
Hello,
I would like to run your code, but there is a mismatch between installed CUDAtoolkits.
Could you tell me what was the version of the packages that you used, specially Tensorflow and Keras?
Thanks in advance.
Razieh
I'm getting this error in Visualizing Intermediate Layer Activations part, I used this model
def M_Model():
base_model = InceptionV3(weights=None, include_top=False, input_shape=(3, 224, 224))
# Classification block
x = GlobalAveragePooling2D(name='avg_pool')(base_model.output)
x = Dense(128, activation='relu')(x)
x = Dropout(0.2)(x)
x = Dense(clse, activation='softmax')(x)
model = Model(inputs=base_model.input, outputs=x)
return model
and the error is :
display_grid[col * size: (col + 1) * size, row * size: (row + 1) * size] = channel_image
ValueError: could not broadcast input array from shape (32,111) into shape (32,32)
Hello,
I am new to TF and I am using TF version 1.13.1
I am using jupyter notebook and I got stuck at following line.
activations = activation_model.predict(img_arr)
When I execute it then it is giving an error as shown below.
`InvalidArgumentError Traceback (most recent call last)
in
----> 1 activations = activation_model.predict(img_arr)
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\keras\engine\training.py in predict(self, x, batch_size, verbose, steps)
1167 batch_size=batch_size,
1168 verbose=verbose,
-> 1169 steps=steps)
1170
1171 def train_on_batch(self, x, y,
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\keras\engine\training_arrays.py in predict_loop(model, f, ins, batch_size, verbose, steps)
292 ins_batch[i] = ins_batch[i].toarray()
293
--> 294 batch_outs = f(ins_batch)
295 batch_outs = to_list(batch_outs)
296 if batch_index == 0:
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\keras\backend\tensorflow_backend.py in call(self, inputs)
2713 return self._legacy_call(inputs)
2714
-> 2715 return self._call(inputs)
2716 else:
2717 if py_any(is_tensor(x) for x in inputs):
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\keras\backend\tensorflow_backend.py in _call(self, inputs)
2669 feed_symbols,
2670 symbol_vals,
-> 2671 session)
2672 if self.run_metadata:
2673 fetched = self._callable_fn(*array_vals, run_metadata=self.run_metadata)
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\keras\backend\tensorflow_backend.py in _make_callable(self, feed_arrays, feed_symbols, symbol_vals, session)
2621 callable_opts.run_options.CopyFrom(self.run_options)
2622 # Create callable.
-> 2623 callable_fn = session._make_callable_from_options(callable_opts)
2624 # Cache parameters corresponding to the generated callable, so that
2625 # we can detect future mismatches and refresh the callable.
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\tensorflow\python\client\session.py in _make_callable_from_options(self, callable_options)
1469 """
1470 self._extend_graph()
-> 1471 return BaseSession._Callable(self, callable_options)
1472
1473
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\tensorflow\python\client\session.py in init(self, session, callable_options)
1423 with errors.raise_exception_on_not_ok_status() as status:
1424 self._handle = tf_session.TF_SessionMakeCallable(
-> 1425 session._session, options_ptr, status)
1426 finally:
1427 tf_session.TF_DeleteBuffer(options_ptr)
c:\users\rameshmdamor777.conda\envs\pythongpu\lib\site-packages\tensorflow\python\framework\errors_impl.py in exit(self, type_arg, value_arg, traceback_arg)
526 None, None,
527 compat.as_text(c_api.TF_Message(self.status.status)),
--> 528 c_api.TF_GetCode(self.status.status))
529 # Delete the underlying status object from memory otherwise it stays alive
530 # as there is a reference to status from this from the traceback due to
InvalidArgumentError: input_3:0 is both fed and fetched.
`
Can you please help me on this.
Thanks
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.