Commit 0d8e548f by Maarten L. Hekkelman

pdb2cif and vv

parent b0965081
......@@ -3416,8 +3416,8 @@ std::tuple<int, int> WriteCoordinatesForModel(std::ostream &pdbFile, const datab
if (type == "branched") // find the real auth_seq_num, since sugars have their auth_seq_num reused as sugar number... sigh.
resSeq = pdbx_branch_scheme.find1<int>("asym_id"_key == r.get<std::string>("label_asym_id") and "pdb_seq_num"_key == resSeq, "auth_seq_num");
else if (type == "non-polymer") // same for non-polymers
resSeq = pdbx_nonpoly_scheme.find1<int>("asym_id"_key == r.get<std::string>("label_asym_id") and "pdb_seq_num"_key == resSeq, "auth_seq_num");
// else if (type == "non-polymer") // same for non-polymers
// resSeq = pdbx_nonpoly_scheme.find1<int>("asym_id"_key == r.get<std::string>("label_asym_id") and "pdb_seq_num"_key == resSeq, "auth_seq_num");
else if (type == "polymer")
resSeq = pdbx_poly_seq_scheme.find1<int>("asym_id"_key == r.get<std::string>("label_asym_id") and "pdb_seq_num"_key == resSeq, "auth_seq_num");
......
......@@ -4203,6 +4203,7 @@ void PDBFileParser::ConstructEntities()
std::map<char, std::string> waterChains;
std::map<std::tuple<std::string, std::string>, int> ndbSeqNum; // for nonpoly scheme
std::map<std::string,int> entityAuthSeqNum; // for nonpoly scheme too
for (size_t i = 0; i < mHets.size(); ++i)
{
......@@ -4331,6 +4332,7 @@ void PDBFileParser::ConstructEntities()
}
int seqNr = ++ndbSeqNum[std::make_tuple(hetID, asymID)];
int authSeqNr = ++entityAuthSeqNum[hetID];
std::string iCode{ het.iCode };
cif::trim(iCode);
......@@ -4343,7 +4345,7 @@ void PDBFileParser::ConstructEntities()
{ "mon_id", hetID },
{ "ndb_seq_num", seqNr },
{ "pdb_seq_num", het.seqNum },
{ "auth_seq_num", het.seqNum }, // Yes
{ "auth_seq_num", authSeqNr }, // Yes
{ "pdb_mon_id", hetID },
{ "auth_mon_id", hetID },
{ "pdb_strand_id", std::string{ het.chainID } },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment