sjtug / SJTUThesis

上海交通大学 LaTeX 论文模板 | Shanghai Jiao Tong University LaTeX Thesis Template
Apache License 2.0
3.38k stars 792 forks source link

参考文献中的url是符合规范的吗,如果不是,如何去掉呢 #497

Closed Hong-Xiang closed 4 years ago

Hong-Xiang commented 4 years ago

问题描述: 参考文献中列表中会包含url信息,例如对于bib中如下的文章:

@article{gonzalez-montoroPerformanceStudyLarge2017,
  title = {Performance {{Study}} of a {{Large Monolithic LYSO PET Detector With Accurate Photon DOI Using Retroreflector Layers}}},
  author = {Gonzalez-Montoro, Andrea and Benlloch, Jose M. and Gonzalez, Antonio J. and Aguilar, Albert and Canizares, Gabriel and Conde, Pablo and Hernandez, Liczandro and Vidal, Luis F. and Galasso, Matteo and Fabbri, Andrea and Sanchez, Filomeno},
  date = {2017-05},
  journaltitle = {IEEE Transactions on Radiation and Plasma Medical Sciences},
  volume = {1},
  pages = {229--237},
  issn = {2469-7311, 2469-7303},
  doi = {10.1109/TRPMS.2017.2692819},
  url = {https://ieeexplore.ieee.org/document/7895212/},
  urldate = {2020-02-22},
  abstract = {Clinical and organ-dedicated PET systems typically require a high efficiency imposing the use of thick scintillators, normally through crystal arrays. To provide depth of interaction (DOI) information, two or more layers are sometimes mounted in the staggered or phoswich approach. In this paper, we are proposing an alternative using thick and large monolithic crystals. We have tested two surface treatments for a 50 mm × 50 mm × 20 mm LYSO block. We provide data in this paper as close as 5 mm to the lateral walls. We left those walls black painted and the exit face coupled to the photosensor (12 × 12 SiPM array) polished. The entrance face was: 1) black painted or 2) coupled to a retroreflector (RR) layer. These configurations keep a good DOI linearity and, on average, reached 4 mm DOI resolution, measured as the full width at half of the maximum. Approaches using RR layers return constant and good energy resolutions nearing 12\%, compared to a range of 15\%–16\% in the case of totally black painted blocks. The best result concerning the detector spatial resolution was obtained when one of the smallest RR was used (120 um corner cube size), being 1.7 mm at the entrance crystal layer and 0.7 mm in the layer closest to the photosensor. These values worsen at least 30\% for the black treatment case.},
  file = <Zotero的本地保存路径>,
  langid = {english},
  number = {3}
}

参考文献中显示如下: image

最后的url信息是否是规范要求的呢? 因为Zotero导出的的Bibtex多数都会包含url,手动删除难度比较大,尤其是考虑到时常需要更新bib库的情况下。


系统信息

模板版本

使用了两个版本都有这个问题,一个是比较早些时候的版本,具体版本号不记得了, 但是是还有着 gb7714-2015.bbxgb7714-2015.cbx 两个文件的板本。 然后更新到了1.0.0rc4,由于论文已经写了,并且sjtuthesis.sty中也有了自定义的指令,所以没有直接从1.0.0rc4的release zip文件上重新写,而是把更新的 compile.bat, latexmkrc, Makefile, sjtuethese-bachelor.ltx, sjtuthesis-graduate.ltx 等文件拷贝,sjtuthesis.sty对照后发现没有改动。


两点小建议

  1. sjtuthesis.sty 文件第六行的版本号似乎没有随着模板的板本更新;
  2. Compile.bat 是否可以指定一个输出目录,比如output/build之类的,这样方便加入.gitignore管理。
Hong-Xiang commented 4 years ago

thesis-bot自动添加的label有点问题,使用选项是

\documentclass[degree=doctor, zihao=-4, language=chinese, review]{sjtuthesis}

area/bachelor标签是否应该删除或者改为area/phd

hushidong commented 4 years ago

去除url,doi可以使用url和doi选项。

见: https://github.com/hushidong/biblatex-gb7714-2015/issues/64

Hong-Xiang commented 4 years ago

@hushidong 谢谢回复。 抱歉我去到https://github.com/hushidong/biblatex-gb7714-2015/issues/64后没有明白应该如何操作。

这个评论中说明修改biblatex的包选项,虽然修改日期还在,但是url可以去掉。 我在SJTUThesis模板中找到biblatex的配置是在sjtuthesis.cls中,修改如下

\RequirePackage[backend=biber,style=\sjtu@bibstyle,url=false,doi=false]{biblatex}

此时确实复现了评论中的状态,没有url了,但是日期还在。

注意到目前SJTUThesis的release的zip中没有gb7714-2015.bbxgb7714-2015.cbx了, 但是master分支上还有,biblatex的style选的是\sjtu@bibstyle, 根据thesis.tex中的说明,bibstyle默认是gb7714-2015

所以请问应该如何把去掉日期的commit 7ce8959的更新部分更新到本地呢?

hushidong commented 4 years ago

将 *.BBX下载下来放到当前目录下,或者覆盖系统中texlive中的对应文件即可。

hushidong commented 4 years ago

这个问题,也是昨天咱们校友小涛给我发邮件发现的。因为现在用zotero等软件得到bib信息往往比较全,所以会输出更多的信息。 这个(公开/更新/修改日期)的问题,我最早也是不考虑的,所以早期版本是没有这个问题的。但后来,为了与国标文档完全一致,所以就加上去了。其实是不需要的。

现在的最新的逻辑是,当给出url时则输出,否则不输出。

Hong-Xiang commented 4 years ago

@hushidong ,谢谢回复。 添加gb7714-2015.bbx到根目录后问题已解决。


有少量特殊情况还保留了日期,比如引用一个网页的话

@online{HowDoesDeep,
  title = {(1) {{How}} Does a Deep Neural Network Escape/Resist the Curse of Dimensionality? - {{Quora}}},
  url = {https://www.quora.com/How-does-a-deep-neural-network-escape-resist-the-curse-of-dimensionality},
  urldate = {2020-02-25},
  file = <文件路径>
}

image 不过这种情况非常特殊,正常也不会引用网页,这个是误操作了,碰巧发现有日期。对于网页来讲确实url必须存在,只是报告一下特殊用例,感觉也不是bug。

hushidong commented 4 years ago

对的,网页类文献,这是必须存在的,否则都不完整。