0
공유 레이어가 CNTK에서 효율적으로 처리됩니까? dual_model
을 평가할 때공유 레이어가 효율적으로 처리됩니까?
def create_func(shared_layers, out1_layers, out2_layers):
# ... there would be a with block specifying activations...omitted for brevity
shared_hl_func = For(shared_layers, lambda n: Dense(n), name="Shared Hidden Layers")
out1_hl_func = For(out1_layers, lambda n: Dense(n), name="Out1 Only Hidden Layers")
out2_hl_func = For(out2_layers, lambda n: Dense(n), name="Sigma Only Hidden Layers")
output1_func = Sequential([shared_hl_func, out1_hl_func,
Dense(1, activation=None, init=init, name="Out1_Regression_Layer")], name="Out1")
output2_func = Sequential([shared_hl_func, out2_hl_func,
Dense(1, activation=None, init=init, name="Out2_Regression_Layer")], name="Out2")
return output1_func, output2_func
output1, output2 = create_func([50,25], [25, 10], [25, 10])
my_input = cntk.input_variable((70,))
dual_model = cntk.combine(output1(my_input), output2(my_input))
계산을 효율적으로 수행 할 것이다 :
서있 예 I는 다음과 같은 식을 가정 (즉, 활성 계산은 중복되지 않고)? (즉, 처음 두 개의 더 넓은 밀도의 레이어는 한 번만 계산 된 후 공유됩니까? 그렇지 않은 경우 명시적인 함수 작성을 통해 효율성을 구성 할 것입니까?
감사합니다. 내 comp 내가 더 많은 레이어를 공유 했음에도 유추 동안 유창 시간은 줄어들지 않았습니다. 내 시스템에서 GraphViz를 사용할 수 없습니다. 이 목적을 위해 TensorBoardProgressWriter로 만든 시각화도 정확합니까? – tarlinian
예, 텐서 보드에서도 모델을 시각화 할 수 있습니다. – KeD