Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
libcifpp
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
libcifpp
Commits
71da0ce3
Unverified
Commit
71da0ce3
authored
Mar 08, 2021
by
Maarten L. Hekkelman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix in fixing distance for LINK records
parent
7dc574b5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
10 deletions
+18
-10
src/PDB2Cif.cpp
+18
-10
No files found.
src/PDB2Cif.cpp
View file @
71da0ce3
...
@@ -5787,20 +5787,28 @@ void PDBFileParser::Parse(std::istream& is, cif::File& result)
...
@@ -5787,20 +5787,28 @@ void PDBFileParser::Parse(std::istream& is, cif::File& result)
{
"ptnr1_label_asym_id"
,
"ptnr1_label_seq_id"
,
"ptnr1_label_atom_id"
,
"ptnr1_symmetry"
,
{
"ptnr1_label_asym_id"
,
"ptnr1_label_seq_id"
,
"ptnr1_label_atom_id"
,
"ptnr1_symmetry"
,
"ptnr2_label_asym_id"
,
"ptnr2_label_seq_id"
,
"ptnr2_label_atom_id"
,
"ptnr2_symmetry"
});
"ptnr2_label_asym_id"
,
"ptnr2_label_seq_id"
,
"ptnr2_label_atom_id"
,
"ptnr2_symmetry"
});
auto
a1
=
atom_site
.
find1
(
"label_asym_id"
_key
==
asym1
and
"label_seq_id"
_key
==
seq1
and
"label_atom_id"
_key
==
atom1
);
try
auto
a2
=
atom_site
.
find1
(
"label_asym_id"
_key
==
asym2
and
"label_seq_id"
_key
==
seq2
and
"label_atom_id"
_key
==
atom2
);
{
auto
a1
=
atom_site
.
find1
(
"label_asym_id"
_key
==
asym1
and
"label_seq_id"
_key
==
seq1
and
"label_atom_id"
_key
==
atom1
);
auto
a2
=
atom_site
.
find1
(
"label_asym_id"
_key
==
asym2
and
"label_seq_id"
_key
==
seq2
and
"label_atom_id"
_key
==
atom2
);
const
auto
&
[
x1
,
y1
,
z1
]
=
a1
.
get
<
float
,
float
,
float
>
({
"cartn_x"
,
"cartn_y"
,
"cartn_z"
});
const
auto
&
[
x1
,
y1
,
z1
]
=
a1
.
get
<
float
,
float
,
float
>
({
"cartn_x"
,
"cartn_y"
,
"cartn_z"
});
const
auto
&
[
x2
,
y2
,
z2
]
=
a2
.
get
<
float
,
float
,
float
>
({
"cartn_x"
,
"cartn_y"
,
"cartn_z"
});
const
auto
&
[
x2
,
y2
,
z2
]
=
a2
.
get
<
float
,
float
,
float
>
({
"cartn_x"
,
"cartn_y"
,
"cartn_z"
});
float
distance
=
1.0
f
;
float
distance
=
1.0
f
;
if
(
symm1
==
"1_555"
and
symm2
==
"1_555"
)
if
(
symm1
==
"1_555"
and
symm2
==
"1_555"
)
distance
=
mmcif
::
Distance
(
mmcif
::
Point
{
x1
,
y1
,
z1
},
mmcif
::
Point
{
x2
,
y2
,
z2
});
distance
=
mmcif
::
Distance
(
mmcif
::
Point
{
x1
,
y1
,
z1
},
mmcif
::
Point
{
x2
,
y2
,
z2
});
else
if
(
cif
::
VERBOSE
)
else
if
(
cif
::
VERBOSE
)
std
::
cerr
<<
"Cannot calculate distance for link since one of the atoms is in another dimension"
<<
std
::
endl
;
std
::
cerr
<<
"Cannot calculate distance for link since one of the atoms is in another dimension"
<<
std
::
endl
;
r
[
"pdbx_dist_value"
]
=
distance
;
r
[
"pdbx_dist_value"
]
=
distance
;
}
catch
(
std
::
exception
&
ex
)
{
if
(
cif
::
VERBOSE
)
std
::
cerr
<<
"Error finding atom: "
<<
ex
.
what
()
<<
std
::
endl
;
}
}
}
}
}
catch
(
const
std
::
exception
&
ex
)
catch
(
const
std
::
exception
&
ex
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment