Highlights
- Pro
PinnedLoading
- Pokemon-Showdown
Pokemon-Showdown PublicForked fromsmogon/pokemon-showdown
Pokemon-Showdown fork optimized for RL training performance.
- This function takes a tensorflow dat...
This function takes a tensorflow dataset and returns a corresponding dataset implementing cutmix 1deftf_ds_cutmix(ds,shuffling=1024):
2ds_shuffled=ds.shuffle(shuffling)
34defcutmix(p1,p2):
5img_1,label_1=p1
- This snippet was used to recover a p...
This snippet was used to recover a proper keras model from a saved model which contained a submodel (ie., one of its layers was actually another model), in order to apply model optimization a posteriori (quantization, pruning). It can be extended to handle more type of layers. 1fromtensorflow.keras.modelsimportSequential
2importtensorflow.keras.layersaskeras_layers
345clone=Sequential()
- A custom tensorflow / keras loss imp...
A custom tensorflow / keras loss implementing OHEM (https://arxiv.org/abs/1604.03540) with cross-entropy. 1importtensorflowastf
2fromtensorflow.keras.lossesimportcategorical_crossentropy
34@tf.function
5defohem_crossentropy_loss(y_true,y_pred):
Something went wrong, please refresh the page to try again.
If the problem persists, check theGitHub status page orcontact support.
If the problem persists, check theGitHub status page orcontact support.