본문 바로가기

for

Apply for/ Apply to ~에 지원하다는 뜻의 apply. 뒤 전치사 for/to 모두 쓰일 수 있지만 서로 다른 조건에서 쓰인다. 결론만 말하면 for는 특정 자리에 to는 (그 자리를 제공하는) 특정 기관에 ex1) She applied for a job at the new company. ex2) She applied to three different universities for her undergraduate studies. 더보기
기간을 나타내는 For와 Over For the past three months, Over the past three months와 같이 For와 Over는 둘다 기간을 나타낼때 쓰일 수 있는 전치사. For는 해당 기간동안 지속적으로 발생하는 사건, 일 등에 관련하여 쓰이고 Over는 해당 기간동안 간헐적으로 발생하는 사건, 일 등에 관련하여 쓰인다. 예시1) For the past three months, we have been involved in this project (O) 예시2) Over the past three months, we conducted several experiments (O) For는 기간동안 지속되는 사건, 일 등에 쓰이기 때문에 have+pp/had+pp와 쓰이지 않으면 매우 어색한 표현이 될 수도 있다.. 더보기
Pytorch how to use nn.ModuleDict with zip for iteration class TEST(nn.Module): def __init__(self): super().__init__() self.conv = nn.Conv2d(10, 10, 1) def forward(self, x): return self.conv(x) num_res = 2 BEVEncoder = nn.ModuleDict() UpSampler = nn.ModuleDict() for _ in range(num_res): IsSelfAttn = True if _ == 0 else False BEVEncoder[str(_)] = TEST() if (_ == 0): UpSampler[str(_)] = None else: UpSampler[str(_)] = TEST() for (_, enc), (_, up) in sort.. 더보기