具有圆形节点的解决方案。
\documentclass[tikz,border=3.14]{standalone}
\begin{document}
\begin{tikzpicture}[
circ/.style = {
circle,
draw,
fill = white,
inner sep = 0pt,
minimum size = 1cm
}
]
\draw (0,0) --++ (4,0) node[circ] {};
\draw (0,-2) --++ (4,0) node[circ, pos=0.5] {};
\end{tikzpicture}
\end{document}