Skip to content

Add a flag to tfjs-converter: --split_weights_by_layer #570

@dsmilkov

Description

@dsmilkov

Problem
We ran across a Keras model that has 174 tiny layers, resulting in 174 weight files of the form group*-shard1of1. This slows down model loading.

Proposed solution
By default, we should create only one weight group and add an optional boolean flag to the tfjs_converter script --split_files_per_layer.

tjs_converter --split_files_per_layer ...
# Will create a weight group for each layer

This flag will only be valid for a Keras model. Other suggestions welcome!

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions