Giter Site home page Giter Site logo

Comments (4)

wuyefeilin avatar wuyefeilin commented on August 17, 2024

我在训练时设置batch_size = 1,CPU_NUM = 1。为什么在利用vis.py画图或eval.py执行评估时,代码test_prog = test_prog.clone(for_test = True)不加for_test = True得效果要比加入for_test是因为batch_norm的缘故吗?难道不是设置batch_size = 1,batch_norm就可以失效了吗?求大神帮忙解答以下。

在测试中,batch_size是不会影响预测结果的。

在卷积运算中,bn是针对每一个通道进行计算的,所以并不能通过将batch_size = 1设置成1让其失效的。

test_prog = test_prog.clone(for_test = True)和不加for_test = True的实验,你能提供一下相关结果吗?以及相应的配置

from paddleseg.

lyf6 avatar lyf6 commented on August 17, 2024

我也遇到了相同的问题,loss和miou都差好多。我选用的配置是pspnet,layers:101
将for_test设置为False的结果:loss=0.09,acc=0.9968,IOU=0.8845
将for_test设置为true的结果:loss=1.417,acc=0.9196,IOU=0.4760

from paddleseg.

wuyefeilin avatar wuyefeilin commented on August 17, 2024

你好,能提供一下具体的运行场景和运行日志吗?

from paddleseg.

lyc1995452-star avatar lyc1995452-star commented on August 17, 2024

请问你们在运行可视化时,出现这种情况没?
Traceback (most recent call last):
File "vis.py", line 212, in
visualize(cfg, **args.dict)
File "vis.py", line 133, in visualize
for imgs, grts, img_names, valid_shapes, org_shapes in test_reader:
File "/PaddleSeg-release-v0.7.0/pdseg/reader.py", line 136, in batch_reader
for img, grt, img_name, valid_shape, org_shape in reader():
File "/PaddleSeg-release-v0.7.0/pdseg/reader.py", line 81, in generator
yield self.process_image(line, self.data_dir, self.mode)
File "/PaddleSeg-release-v0.7.0/pdseg/reader.py", line 251, in process_image
line, data_dir, mode=mode)
File "/PaddleSeg-release-v0.7.0/pdseg/reader.py", line 205, in load_image
grt_height = grt.shape[0]
IndexError: tuple index out of range

from paddleseg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.