Skip to content

Conversation

@sjtuzyk
Copy link
Contributor

@sjtuzyk sjtuzyk commented Oct 13, 2018

No description provided.

Copy link
Owner

@liweitianux liweitianux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

另外,需要同步更新那个 HOWTO.txt

多谢!

parser.add_argument("-s", "--step", dest="step", type=int, default=5,
help="calculation step (default:5)")
parser.add_argument("-o", "--outfile", dest="outfile",
default="spc_reg.reg",
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

之前的默认文件名是 rspec.reg,继续用原来的。

parser.add_argument("-H", "--ehigh", dest="ehigh", type=int, default=7000,
help="upper energy limit [eV] (default: 7000 [eV])")
parser.add_argument("-s", "--step", dest="step", type=int, default=5,
help="calculation step (default:5)")
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

calculation step 没说清楚这个参数是用来做什么的。这个说明写长一点没关系。另外还要说明这个数的单位是什么。



def genspecreg(evtfile, bkg_spec, outfile, reg_centroid,
step=5, cnts_min=2500):
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. 函数名称改为 gen_regions()
  2. 这个函数太长了,处理的事情太多。我觉得应当拆分成大概 3 个函数。

比如,reg_centroid 应为 center,直接提供中心坐标,而不要在这个函数里去解析区域文件。

parser.add_argument("-L", "--elow", dest="elow", type=int, default=700,
help="lower energy limit [eV] (default: 700 [eV])")
parser.add_argument("-H", "--ehigh", dest="ehigh", type=int, default=7000,
help="upper energy limit [eV] (default: 7000 [eV])")
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

增加一个参数 --min-counts 表示每个分区里(扣除背景后)的最少光子数,默认为 2500

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants