<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_load_constant(self, name, output_name, constant_value, shape):
 """ Add a load constant layer. Parameters name: str The name of this layer. output_name: str The output blob name of this layer. constant_value: numpy.array value of the constant as a numpy array. shape: [int] List of ints representing the shape of the constant. Must be of length 3: [C,H,W] See Also -------- add_elementwise """

        spec = self.spec
        nn_spec = self.nn_spec

        # Add a new layer
        spec_layer = nn_spec.layers.add()
        spec_layer.name = name
        spec_layer.output.append(output_name)

        spec_layer_params = spec_layer.loadConstant

        data = spec_layer_params.data
        data.floatValue.extend(map(float, constant_value.flatten()))

        spec_layer_params.shape.extend(shape)

        if len(data.floatValue) != np.prod(shape):
            raise ValueError("Dimensions of 'shape' do not match the size of the provided constant")
        if len(shape) != 3:
            raise ValueError("'shape' must be of length 3")