fpn.pytorch icon indicating copy to clipboard operation
fpn.pytorch copied to clipboard

No such file or directory:log

Open KevinQian97 opened this issue 7 years ago • 3 comments

Hi, I am encountered with a problem.

Here is the relevant feedback :

Called with args: Namespace(batch_size=4, checkepoch=1, checkpoint=0, checkpoint_interval=10000, checksession=1, class_agnostic=False, cuda=True, dataset='pascal_voc', disp_interval=100, lr=0.01, lr_decay_gamma=0.1, lr_decay_step=10, lscale=False, mGPUs=True, max_epochs=20, net='res101', num_workers=0, optimizer='sgd', resume=False, save_dir='/DATACENTER2/qyj/fpn.pytorch-master/models', session=1, start_epoch=1, use_tfboard=False) Traceback (most recent call last): File "trainval_net.py", line 167, in filemode='w', level=logging.DEBUG) File "/home/zhiqi.cheng/anaconda2/lib/python2.7/logging/init.py", line 1547, in basicConfig hdlr = FileHandler(filename, mode) File "/home/zhiqi.cheng/anaconda2/lib/python2.7/logging/init.py", line 913, in init StreamHandler.init(self, self._open()) File "/home/zhiqi.cheng/anaconda2/lib/python2.7/logging/init.py", line 943, in _open stream = open(self.baseFilename, self.mode) IOError: [Errno 2] No such file or directory: '/DATACENTER2/qyj/fpn.pytorch-master/logs/res101_pascal_voc_1.log'

I found that in the code it has these lines: if args.use_tfboard: from model.utils.logger import Logger # Set the logger logger = Logger('./logs')

logging.basicConfig(filename="logs/"+args.net+""+args.dataset+""+str(args.session)+".log", filemode='w', level=logging.DEBUG) logging.info(str(datetime.now()))

I really appreciate for your help.

KevinQian97 avatar Aug 31 '18 21:08 KevinQian97

I have solved the problem. Thank you. You can close the issue BTW, would you mind help me solve the problem https://github.com/jwyang/fpn.pytorch/issues/25#issue-356315817 which is similar to https://github.com/jwyang/fpn.pytorch/issues/13#issue-331048159

KevinQian97 avatar Sep 05 '18 02:09 KevinQian97

you have to built a folder named "logs" ,I met this issue,too

XinZhangRadar avatar Oct 11 '18 16:10 XinZhangRadar

Can you tell me how you solved this problem? I met the same one.

maojiaoli avatar Dec 27 '19 04:12 maojiaoli