In [19]:
data = """
Vescan, A.,Serban, C., Multilevel component selection optimization toward an optimal architecture , Soft Computing , no. 21, pp. 4481–4495, 2017. disclaimer https://link-springer-com.am.e-nformation.ro/article/10.1007/s00500-016-2472-8 (IF=2.367 in 2017, Rank Q2)
2010-2012 and 2013-2014
Vescan, A., Optimal component selection using a multiobjective evolutionary algorithm, International Journal on non-standard computing and artificial intelligence: Neural Network World, no. 2, pp. 201- 213, 2009. disclaimer pdf bibtex, http://www.nnw.cz/ (Rank Q4 in 2009)
Fanea, A., Diosan, L., Evolutionary Approach for Behaviour Component Composition, International Journal of Computers, Communications & Control (IJCCC), pp. 480- 485, 2006.disclaimer pdf bibtex, http://www.journal.univagora.ro/
Fanea, A., Diosan, L., Computational Intelligence-based Model for Component Composition Analysis, International Journal of Computers, Communications & Control (IJCCC), pp. 474- 479, 2006.disclaimer pdf bibtex, http://www.journal.univagora.ro
ISI Conference Proceedings
Vescan, A., Şerban,C., Chisăliţă-Cretu, C., Dioşan, L., Requirement Dependencies-based Formal Approach for Test Case Prioritization in Regression Testing ,13th IEEE International Conference on Intelligent Computer Communication and Processing (ICCP) Location: Cluj Napoca, ROMANIA Date: SEP 07-09, pp. 181-188 , 2017 disclaimer https://ieeexplore.ieee.org/document/8117002
Vescan, A., Case Study Method and Research Design for the Dynamic Multilevel Component Selection Problem, 13th International Conference on Service-Oriented Computing (ICSOC) Location: Goa, INDIA Date: NOV 16-19, 2015, SERVICE-ORIENTED COMPUTING - ICSOC 2015 WORKSHOPS Book Series: Lecture Notes in Computer Science Volume: 9586 Pages: 130-141, Published: 2016
Vescan, A., An Evolutionary Multiobjective Approach for the Dynamic Multilevel Component Selection Problem, 13th International Conference on Service-Oriented Computing (ICSOC) Location: Goa, INDIA Date: NOV 16-19, 2015, SERVICE-ORIENTED COMPUTING - ICSOC 2015 WORKSHOPS Book Series: Lecture Notes in Computer Science Volume: 9586 Pages: 193-204, Published: 2016
Vescan, A., Şerban,C., A Fuzzy-Based Approach for the Multilevel Component Selection Problem, Conference: 11th International Conference on Hybrid Artificial Intelligence Systems (HAIS) Location: Seville, SPAIN Date: APR 18-20, 2016, Book Series: Lecture Notes in Artificial Intelligence Volume: 9648 Pages: 463-474 Published: 2016
Motogna, S., Vescan, A., Şerban,C., Tirban, P., An Approach to Assess Maintainability Change, IEEE International Conference on Automation, Quality and Testing, Robotics (AQTR) , pp. 25-30, 2016
Motogna, S., Ciuciu, I., Serban, C., Vescan, A., Improving Software Quality Using an Ontology-Based Approach, OnTheMove (OTM) Federated Conference Location: Rhodes, GREECE Date: OCT 26-30, 2015, ON THE MOVE TO MEANINGFUL INTERNET SYSTEMS: OTM 2015 WORKSHOPS Book Series: Lecture Notes in Computer Science Volume: 9416 Pages: 456-465 Published: 2015
2010-2012 and 2013-2014 - Parental leave
C. Serban, A. Vescan, H. F. Pop, A conceptual framework for component-based system metrics definition, 9th RoEduNet International Conference, Sibiu, Romania, ISSN: 2068-1038, Print ISBN: 978-1-4244-7335-9, pp. 73-78, 24-26 June 2010, disclaimer pdf bibtex, http://www.roedu2010.ulsibiu.ro
Vescan, A., A Metrics-based Evolutionary Approach for the Component Selection Problem, the 11th International Conference on Computer Modelling and Simulation (UKSim 2009), pp. 83-88, 2009. http://www.uksim2009.org.uk/ disclaimer bibtex pdf
Serban, C., Vescan, A., Pop, H. F., A new Component Selection Algorithm Based on Metrics and Fuzzy Clustering Analysis, Proceedings of the 4th International Conference on Hybrid Artificial Intelligence Systems, 10 - 12 June, Salamanca, Spain, LNCS Vol. 5572, Corchado, E.; Wu, X.; Oja, E.; Herrero, A.; Baruque, B. (Eds.), ISBN: 978-3-642-02318-7, pp. 621 – 628, 2009. http://gicap.ubu.es/hais2009/ disclaimer bibtex pdf
Chisalita-Cretu, C., Vescan, A., The multi-objective refactoring selection problem, Conference on Knowledge Engineering Principles and Techniques, Cluj-Napoca, Romania, JUL 02-04, 2009, pp: 291-298. disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/kept2009/
Vescan, A., Grosan, C., A Hybrid Evolutionary Multiobjective Approach for the Component Selection Problem, Proceedings of the 3rd International Workshop on Hybrid Artificial Intelligence Systems, 24 - 26 September, Burgos, Spain, LNCS/LNAI 5271, Eds.: Corchado, Emilio; Abraham, Ajith; Pedrycz, Witold, ISBN: 978-3-540-87655-7, pp, 164-171, 2008. disclaimer bibtex pdf, http://www2.ubu.es/hais2008/
Vescan, A., An evolutionary multiobjective approach for the Component Selection Problem, Proceedings of the First IEEE International Conference on the Applications of Digital Information and Web Technologies (ICADIWT), 4 - 6 August, Ostrava, Czech Republic, ISBN: 978-1-444-264-9, pp. 252-257, 2008. (indexed IEEE) disclaimer bibtex pdf,http://www.dirf.org/diwt2008/
Vescan, A., Grosan, C., Two Evolutionary Multiobjective Approaches for the Component Selection Problem, Proceedings of the Fourth International Workshop on Evolutionary Multiobjective Optimization – Design and Applications, 26 - 28 November, Kaohsiung, Taiwan, Eds: Jeng-Shyang Pan,Ajith Abraham,Chin-Chen Chang, Vol 2, ISBN: 978-0-7695-3382-7, pp. 395 - 400, 2008. (indexed IEEE) disclaimer bibtex pdf, http://bit.kuas.edu.tw/~isda08/
Vescan, A., Grosan, C., Pop, H. F., Evolutionary Algorithms for the Component Selection Problem, Proceedings of the 2nd International Workshop Evolutionary Techniques in Data Processing, 1 - 5 September, Turin, Italy, pp. 509-513, 2008., http://www.dexa.org/previous/dexa2008/index.html disclaimer bibtex pdf
Vescan, A., Component Adaptation Architectures. A Formal Approach, Proceedings of the 12th International Conference on Knowledge-Based Intelligent Information and Engineering Systems, Invited session on Evolvable Hardware and Adaptive Systems - Advanced Engineering Design Methodologies and Applications, 3 - 5 September, Zagreb, Croatia, LNCS/LNAI 5179, Eds.: Lovrek, Ignac; Howlett, Robert J.; Jain, Lakhmi C., ISBN: 978-3-540-85566-8, pp. 319-326, 2008, http://www.bel.utcluj.ro/ci/kes/kes_adaptive.htm disclaimer bibtex pdf
Vescan, A., Restraint Order Component Model Execution, Proceedings of the International Symposium on Symbolic and Numeric Algorithms for Scientific Computing, 26 - 29 September, Timisoara, Romania, IEEE Computer Society Press, pp. 195 - 200, ISBN: 0-7695-2740-X, 2006. disclaimer bibtex pdf,http://www.computer.org
Lazar, Z., Fanea, A., Petrascu, D., Ciobotariu-Boer, V., Parv, B., COMODI: On the Graphical User Interface, Proceedings of the 7th International Symposium on Symbolic and Numeric Algorithms for Scientific Computing (SYNASC05), 25 - 29 September, Timisoara, Romania, IEEE Computer Society Press, pp 109 - 113, ISBN: 0-7695-2453-2, 2005. disclaimer bibtex pdf,http://www.computer.org
Miclaus, A., Petrescu, S., Vescan, A., Embedded Systems with Component-Based GPU Support: A State of the Art, Studia Universitatis Babeș-Bolyai Informatica, [S.l.], v. 64, n. 1, p. 67-76, june 2019. ISSN 2065-9601.
Vescan, A.. Third Case Study for the Dynamic Multilevel Component Selection. Studia Universitatis Babeș-Bolyai Informatica, [S.l.], v. 62, n. 1, p. 15-31, may 2017. ISSN 2065-9601.
Serban, C., Vescan, A., Pop, H. F., Preliminary Measurements in Identifying Design Flaws. Studia Universitatis Babeș-Bolyai Informatica, [S.l.], v. 62, n. 1, p. 60-74, may 2017. ISSN 2065-9601.
Motogna, S., Serban, C., Vescan, A., METRICS-BASED REFACTORING STRATEGY AND IMPACT ON SOFTWARE QUALITY, KNOWLEDGE ENGINEERING: PRINCIPLES AND TECHNIQUES, Proceedings of the International Conference on Knowledge Engineering, Principles and Techniques, KEPT2015, Cluj-Napoca (Romania), July 24, 2015, pp. 2527. disclaimer bibtex
2010-2012 and 2013-2014 - Parental leave
Vescan, A., Pop, H. F., Automatic Criteria-based Configuration for the Component Selection Problem, International Journal of Computer Information Systems and Industrial Managements Applications, Vol. 4, pp. 641-647, 2012 ( ISSN 2150-7988 [indexed INSPEC] disclaimer bibtex ,http://www.mirlabs.net/ijcisim
C-M.Pintea, A.Vescan, Bio-inspired components for a bandwidth problem, Scientific Studies and Research, Seria Mathematics and Informatics, 21(1), 185-192 , 2011 (ISSN 2067-3566)[indexed Zbl] disclaimer bibtex pdf
Vescan, A., Grosan, C, Evolutionary multiobjective approach for multilevel component composition, Studia Universitatis Babes-Bolyai, Series Informatica, Volume LV, Number 4, pp.18-32 2010 disclaimer bibtex pdf, http://www.ams.org/mathscinet/, http://www.cs.ubbcluj.ro/~studia-i/
Vescan, A., Frentiu, M, Teaching Model Checking to Undergraduates, Studia Universitatis Babes-Bolyai, Series Informatica, Volume LV, Number 3, pp.45-50, 2010 disclaimer bibtex pdf, http://www.ams.org/mathscinet/, http://www.cs.ubbcluj.ro/~studia-i/
Vescan Andreea (Fanea), Chisalita-Cretu Maria Camel, The multi-objective refactoring selection problem, Studia Universitatis Babes-Bolyai, Series Informatica, pp.249-253, 2009. (indexed MathSciNet) disclaimer bibtex pdf
Vescan, A., Dependencies in the Component Selection Problem, Creative Mathematics and Informatics, pp.532-537, 2008, disclaimer bibtex pdf
Serban, C, Vescan, A., Pop, H. F, Selection based on Fuzzy Clustering Analysis, Creative Mathematics and Informatics, pp.505-510, 2008. disclaimer bibtex pdf
Vescan, A., Pop, H. F., Constraint Optimization-based Component Selection Problem, Studia Universitatis Babes-Bolyai, series Informatica, Vol. LIII, 2/2008, pp. 3-14 (indexed MathSciNet) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2008-2/
Pintea, C.-M., Vescan, A., Component-based Ant System for a Biobjective Assignment Problem, Studia Universitas Babes-Bolyai, Seria Informatica, year LII, (2007), pp. 21 - 32. (indexed MathSciNet) disclaimer bibtex pdf
http://www.cs.ubbcluj.ro/~studia-i/2007-2/index.php1., http://www.cs.ubbcluj.ro/~studia-i/2007-2/index.php1.
Serban, C., Vescan, A., Metrics-based selection of a component assembly, Special Issue of Studia Universitatis Babes-Bolyai, Seria Informatica: Proceedings of The International Conference on Knowledge Engineering: Principles and Techniques, 6 -8 June, Cluj-Napoca, Romania, University Press, pp.324 - 331, ISBN:978-973-610-556-2, 2007. (indexed MathSciNet) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2007-kept/index.php
Vescan, A., Pintea, C.-M., Ant Colony Component-based System for Traveling Salesman Problem, Journal of Applied Mathematical Science, ISSN 1312- 885X, vol. 1, no. 25-28, pp. 1347 - 1357, 2007. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://m-hikari.com/ams/
Vescan, A., Motogna, S., Overview and Architecture of a Component Modeling Tool, Creative Mathematics and Informatics, vol. 16, pp. 159 - 165, ISSN: 1843-441X, 2007. (indexed MathSciNet) disclaimer bibtex pdf
http://creative-mathematics.ubm.ro
Serban, C., Vescan, A., Metrics for Component-Based System Development, Creative Mathematics and Informatics, vol. 16, pp. 143 - 150, ISSN: 1843-441X, 2007. (indexed MathSciNet) disclaimer bibtex pdf, http://creative-mathematics.ubm.ro
Vescan, A., Motogna, S., Syntactic analysis of component composition, Journal of Pure Mathematics and Applications, Proceedings of the 6th Joint Conference on Mathematics and Computer Science, Pecs, Hungary, 12 - 15 July, Vol. 17, No. 3 - 4, pp. 527–537, 2006. (indexed MathSciNet)
http://www.bke.hu/puma
Fanea, A., Diosan, L., Component Based Model Using P Systems, The International Journal of Information Technology and Intelligent Computing, ISSN: 1895-8648, vol.1 no.3, pp. 499 - 508, 2006
http://itic.wshe.lodz.pl
Diosan, L., Fanea, A., Dumitrescu, D., Genetic algorithms based on Ising machine, International Journal of Information Technology and Intelligent Computing, ISSN: 1895-8648, vol.1 no.3, pp. 585 - 594, 2006.
http://itic.wshe.lodz.pl
Fanea, A., Motogna, S., Diosan, L., Automata-Based Component Composition Analysis, Studia Universitas Babes-Bolyai, Seria Informatica, Vol. LI, No. 1, pp. 13 - 20, 2006. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2006-1/index.php
Fanea, A., Diosan, L., Components Execution Order using Genetic Algorithms, Studia Universitas Babes-Bolyai, Seria Informatica, Volume L, No. 2, pp. 23 - 32, 2005. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2005-2/
Fanea, A., Pintea, C.-M., A component based-model for a NP-hard problem, Annals of Oradea University, Fascicola Matematica, Vol.XII, pp. 91 - 100, 2005. (indexed MathSciNet, ZMath) disclaimer bibtex pdf
http://stiinte.uoradea.ro/en/auofm_contents.htm
Lazar, Z. I., Pârv,B., Fanea, A., Heringa, J. R., de Leeuw, S. W., COMODI: Guidelines for a Component-Based Framework for Scientific Computing, Studia Universitatis Babes-Bolyai, Informatica, Vol. XLIX, No. 2, pp. 91 - 101, 2004. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2004-2/
"""
In [20]:
books = """
2011
A.Vescan, C-M.Pintea, Component-based Ant Systems in "Modern Paradigms in Computer Science and Applied Mathematics", A Handbook for PhD Students and Researchers, (Eds.B.Patrut, G-C.Crisan), Akademische Verlagsgemeinschaft München-AVM-GmbH&Co.KG, München, Germany, 2011 (ISBN 978-3-86306-757-1) buy bibtex
2008
Vescan, A, Construction Approaches for Component-Based Systems. PhD Thesis, Cluj-Napoca : Universitatea "Babeş-Bolyai", 2008 Biblioteca Nationala: http://aleph.bibnat.ro C-M.Pintea, A.Vescan, C.Vescan, Grafica in Delphi,Ed.EduSoft (CNCSIS cod:157) 2008 (ISBN 978-973-8934-92-4)bibtex
"""
In [21]:
journals = """
Miclaus, A., Petrescu, S., Vescan, A., Embedded Systems with Component-Based GPU Support: A State of the Art, Studia Universitatis Babeș-Bolyai Informatica, [S.l.], v. 64, n. 1, p. 67-76, june 2019. ISSN 2065-9601.
Vescan, A.. Third Case Study for the Dynamic Multilevel Component Selection. Studia Universitatis Babeș-Bolyai Informatica, [S.l.], v. 62, n. 1, p. 15-31, may 2017. ISSN 2065-9601.
Serban, C., Vescan, A., Pop, H. F., Preliminary Measurements in Identifying Design Flaws. Studia Universitatis Babeș-Bolyai Informatica, [S.l.], v. 62, n. 1, p. 60-74, may 2017. ISSN 2065-9601.
Motogna, S., Serban, C., Vescan, A., METRICS-BASED REFACTORING STRATEGY AND IMPACT ON SOFTWARE QUALITY, KNOWLEDGE ENGINEERING: PRINCIPLES AND TECHNIQUES, Proceedings of the International Conference on Knowledge Engineering, Principles and Techniques, KEPT2015, Cluj-Napoca (Romania), July 24, 2015, pp. 2527. disclaimer bibtex
2010-2012 and 2013-2014 - Parental leave
Vescan, A., Pop, H. F., Automatic Criteria-based Configuration for the Component Selection Problem, International Journal of Computer Information Systems and Industrial Managements Applications, Vol. 4, pp. 641-647, 2012 ( ISSN 2150-7988 [indexed INSPEC] disclaimer bibtex ,http://www.mirlabs.net/ijcisim
C-M.Pintea, A.Vescan, Bio-inspired components for a bandwidth problem, Scientific Studies and Research, Seria Mathematics and Informatics, 21(1), 185-192 , 2011 (ISSN 2067-3566)[indexed Zbl] disclaimer bibtex pdf
Vescan, A., Grosan, C, Evolutionary multiobjective approach for multilevel component composition, Studia Universitatis Babes-Bolyai, Series Informatica, Volume LV, Number 4, pp.18-32 2010 disclaimer bibtex pdf, http://www.ams.org/mathscinet/, http://www.cs.ubbcluj.ro/~studia-i/
Vescan, A., Frentiu, M, Teaching Model Checking to Undergraduates, Studia Universitatis Babes-Bolyai, Series Informatica, Volume LV, Number 3, pp.45-50, 2010 disclaimer bibtex pdf, http://www.ams.org/mathscinet/, http://www.cs.ubbcluj.ro/~studia-i/
Vescan Andreea (Fanea), Chisalita-Cretu Maria Camel, The multi-objective refactoring selection problem, Studia Universitatis Babes-Bolyai, Series Informatica, pp.249-253, 2009. (indexed MathSciNet) disclaimer bibtex pdf
Vescan, A., Dependencies in the Component Selection Problem, Creative Mathematics and Informatics, pp.532-537, 2008, disclaimer bibtex pdf
Serban, C, Vescan, A., Pop, H. F, Selection based on Fuzzy Clustering Analysis, Creative Mathematics and Informatics, pp.505-510, 2008. disclaimer bibtex pdf
Vescan, A., Pop, H. F., Constraint Optimization-based Component Selection Problem, Studia Universitatis Babes-Bolyai, series Informatica, Vol. LIII, 2/2008, pp. 3-14 (indexed MathSciNet) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2008-2/
Pintea, C.-M., Vescan, A., Component-based Ant System for a Biobjective Assignment Problem, Studia Universitas Babes-Bolyai, Seria Informatica, year LII, (2007), pp. 21 - 32. (indexed MathSciNet) disclaimer bibtex pdf
http://www.cs.ubbcluj.ro/~studia-i/2007-2/index.php1., http://www.cs.ubbcluj.ro/~studia-i/2007-2/index.php1.
Serban, C., Vescan, A., Metrics-based selection of a component assembly, Special Issue of Studia Universitatis Babes-Bolyai, Seria Informatica: Proceedings of The International Conference on Knowledge Engineering: Principles and Techniques, 6 -8 June, Cluj-Napoca, Romania, University Press, pp.324 - 331, ISBN:978-973-610-556-2, 2007. (indexed MathSciNet) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2007-kept/index.php
Vescan, A., Pintea, C.-M., Ant Colony Component-based System for Traveling Salesman Problem, Journal of Applied Mathematical Science, ISSN 1312- 885X, vol. 1, no. 25-28, pp. 1347 - 1357, 2007. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://m-hikari.com/ams/
Vescan, A., Motogna, S., Overview and Architecture of a Component Modeling Tool, Creative Mathematics and Informatics, vol. 16, pp. 159 - 165, ISSN: 1843-441X, 2007. (indexed MathSciNet) disclaimer bibtex pdf
http://creative-mathematics.ubm.ro
Serban, C., Vescan, A., Metrics for Component-Based System Development, Creative Mathematics and Informatics, vol. 16, pp. 143 - 150, ISSN: 1843-441X, 2007. (indexed MathSciNet) disclaimer bibtex pdf, http://creative-mathematics.ubm.ro
Vescan, A., Motogna, S., Syntactic analysis of component composition, Journal of Pure Mathematics and Applications, Proceedings of the 6th Joint Conference on Mathematics and Computer Science, Pecs, Hungary, 12 - 15 July, Vol. 17, No. 3 - 4, pp. 527–537, 2006. (indexed MathSciNet)
http://www.bke.hu/puma
Fanea, A., Diosan, L., Component Based Model Using P Systems, The International Journal of Information Technology and Intelligent Computing, ISSN: 1895-8648, vol.1 no.3, pp. 499 - 508, 2006
http://itic.wshe.lodz.pl
Diosan, L., Fanea, A., Dumitrescu, D., Genetic algorithms based on Ising machine, International Journal of Information Technology and Intelligent Computing, ISSN: 1895-8648, vol.1 no.3, pp. 585 - 594, 2006.
http://itic.wshe.lodz.pl
Fanea, A., Motogna, S., Diosan, L., Automata-Based Component Composition Analysis, Studia Universitas Babes-Bolyai, Seria Informatica, Vol. LI, No. 1, pp. 13 - 20, 2006. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2006-1/index.php
Fanea, A., Diosan, L., Components Execution Order using Genetic Algorithms, Studia Universitas Babes-Bolyai, Seria Informatica, Volume L, No. 2, pp. 23 - 32, 2005. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2005-2/
Fanea, A., Pintea, C.-M., A component based-model for a NP-hard problem, Annals of Oradea University, Fascicola Matematica, Vol.XII, pp. 91 - 100, 2005. (indexed MathSciNet, ZMath) disclaimer bibtex pdf
http://stiinte.uoradea.ro/en/auofm_contents.htm
Lazar, Z. I., Pârv,B., Fanea, A., Heringa, J. R., de Leeuw, S. W., COMODI: Guidelines for a Component-Based Framework for Scientific Computing, Studia Universitatis Babes-Bolyai, Informatica, Vol. XLIX, No. 2, pp. 91 - 101, 2004. (indexed MathSciNet, ZMath) disclaimer bibtex pdf, http://www.cs.ubbcluj.ro/~studia-i/2004-2/
"""
In [22]:
def IsDate(line):
if line == "":
return False
for c in line:
if c not in "1234567890 ":
return False
return True
In [23]:
def ProcessBook(line):
sp = line.split(',')
# print(sp)
sp_tups = [(len(k), k) for k in sp]
sp_tups.sort(reverse=True)
# print(sp_tups)
title = sp_tups[0][1]
affiliations = sp_tups[1][1]
authors = [k for k in sp if "." in k and k.lstrip()[0] in "ABCDEFGHIJLKMNOPQRSTUVWXYZ" and len(k) < 24]
return title, affiliations, ", ".join(authors)
In [24]:
for line in books.split('\n'):
# print(line)
# print("lnbr")
if IsDate(line):
continue
if line != "":
title, affiliations, authors = ProcessBook(line)
print("title: ", title)
print("affiliations: ", affiliations)
print("authors: ", authors)
In [28]:
pubs = []
for line in data.split('\n'):
# print(line)
# print("lnbr")
if len(line.split(' ')) < 8:
continue
if IsDate(line):
continue
if line != "":
title, affiliations, authors = ProcessBook(line)
print("title: ", title)
print("affiliations: ", affiliations)
# print("authors: ", authors)
pubs.append((title, affiliations))
In [32]:
import mariadb
import json
In [33]:
with open('../credentials.json', 'r') as crd_json_fd:
json_text = crd_json_fd.read()
json_obj = json.loads(json_text)
In [34]:
credentials = json_obj["Credentials"]
username = credentials["username"]
password = credentials["password"]
In [35]:
table_name = "publications_cache"
db_name = "ubbcluj"
In [36]:
mariadb_connection = mariadb.connect(user=username, password=password, database=db_name)
mariadb_cursor = mariadb_connection.cursor()
In [42]:
ctr = 0
for paper in pubs:
title = ""
pub_date = ""
authors = ""
try:
pub_date = paper[2].lstrip()
pub_date = str(pub_date) + "-01-01"
if len(pub_date) != 10:
pub_date = ""
except:
pass
try:
title = paper[0].lstrip()
except:
pass
try:
affiliations = paper[1].lstrip()
except AttributeError:
pass
insert_string = "INSERT INTO {0} SET ".format(table_name)
insert_string += "Title=\'{0}\', ".format(title)
insert_string += "ProfessorId=\'{0}\', ".format(17)
if pub_date != "":
insert_string += "PublicationDate=\'{0}\', ".format(str(pub_date))
#insert_string += "Authors=\'{0}\', ".format(authors)
insert_string += "Affiliations=\'{0}\' ".format(affiliations)
# print(insert_string)
print(affiliations)
ctr += 1
# continue
# raise NotImplementedError ("win")
try:
mariadb_cursor.execute(insert_string)
except mariadb.ProgrammingError as pe:
print("Error")
raise pe
except mariadb.IntegrityError:
continue
print(ctr)
In [ ]: