def add_reshape_dynamic(self, name, input_names, output_name):
        """
        Add a reshape_dynamic layer to the model that reshapes a tensor.
        Refer to the ``ReshapeDynamicLayerParams`` message in the specification
        (NeuralNetwork.proto) for more details.

        Parameters
        ----------
        name: str
            The name of this layer.
        input_names: list of str
            The input blob names of this layer.
        output_name: str
            The output blob name of this layer.

        See Also
        --------
        add_reshape, add_reshape_like, add_reshape_static, add_rank_preserving_reshape
        """

        spec_layer = self._add_generic_layer(name, input_names, [output_name])
        spec_layer.reshapeDynamic.MergeFromString(b"")
        # Setting rank to -1 is a hint that Rank was not computed
        # converter can modify if it's a constant and known
        self.rank_dict[output_name] = -1
        return spec_layer

        Add a reshape_dynamic layer to the model that reshapes a tensor.
        Refer to the ``ReshapeDynamicLayerParams`` message in the specification
        (NeuralNetwork.proto) for more details.

        Parameters
        ----------
        name: str
            The name of this layer.
        input_names: list of str
            The input blob names of this layer.
        output_name: str
            The output blob name of this layer.

        See Also
        --------
        add_reshape, add_reshape_like, add_reshape_static, add_rank_preserving_reshape
        
coremltools/models/neural_network/builder.py