Skip to content

Commit 4334d8d

Browse files
committed
first draft
1 parent ac2d87f commit 4334d8d

File tree

9 files changed

+510
-9
lines changed

9 files changed

+510
-9
lines changed

.DS_Store

0 Bytes
Binary file not shown.

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
Use the following command to build
44

55
```
6+
conda activate dev
67
jb build docs --path-output ./ -nW --keep-going
78
```

docs/.DS_Store

0 Bytes
Binary file not shown.

docs/_toc.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ parts:
55
numbered: false
66
maxdepth: 1
77
chapters:
8+
- file: posts/research/a
89
- file: posts/research/project1
910
- file: posts/research/project2
1011
- file: posts/research/publication

docs/images/cluster_plot.png

154 KB
Loading

docs/posts/open_source/gsoc.md

Lines changed: 150 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,151 @@
1-
# Google Summer of Code
1+
# Google Summer of Code 2023
22

3-
This is my Google Summer of Code blog.
3+
## Extending the data structures and algorithms along with providing C++ backend
4+
5+
**Project Mentors**: Gagandeep Singh, Ivan Ogasawara, Smit Lunagariya, Ever Vino, Alexandre de Siqueira, Agustina Pesce, Saransh Chopra
6+
7+
This is the final report of the entire GSoC 2023 for the project titled as **Extending the data structures and algorithms along with providing C++ backend**. The complete description of the project implementation and discussions of the entire program is available at my [personal blog site](https://sak-codes.github.io).
8+
9+
### About Me
10+
11+
I am **Sakshi Oza**, final year Masters student at Indian Institute of Technology, Gandhinagar.
12+
13+
### Project Overview: Phase-wise short description
14+
15+
I divided the whole project into three main phases to work on the specific topics that were supposed to be implemented during the GSoC.
16+
17+
1. **Community Bonding & Pre-GSOC**: During this phase, I mainly focused
18+
on the easier topics that help me to get started with the official coding
19+
timeline. I dedicated my efforts to gaining a thorough understanding of the codebase.
20+
21+
2. **Phase 1**: This phase consists of the official coding before prior to
22+
the mid evaluation. This phase was mainly focused on extending the existing
23+
scope of data structures and algorithms as well as fixing the existing
24+
issues.
25+
26+
2. **Phase 2**: This phase consists of the official coding after the
27+
the mid evaluation. This phase included working on some new data structures
28+
along with adding the CPP backend to the current algorithms under the
29+
`linear_data_structures` submodule.
30+
31+
32+
### Pull Requests
33+
This section describes the actual work done during the coding period in terms of merged pull requests.
34+
35+
36+
**Community Bonding & Pre-GSOC**
37+
38+
- [#516](https://github.com/codezonediitj/pydatastructs/pull/516) - This PR
39+
implements a method in `DSU` to find the size of the group of the given key.
40+
41+
- [#517](https://github.com/codezonediitj/pydatastructs/pull/517) - This PR
42+
adds a method in the class `Trie` to check if the string as inserted before.
43+
44+
- [#521](https://github.com/codezonediitj/pydatastructs/pull/521) - This PR
45+
implements a method to print all the members of the same group in `DSU`.
46+
47+
**Phase 1**
48+
49+
- [#530](https://github.com/codezonediitj/pydatastructs/pull/530) - This PR
50+
closes the [issue-478](https://github.com/codezonediitj/pydatastructs/issues/478) by implementing the network flow algorithms: Edmond Karp.
51+
52+
- [#534](https://github.com/codezonediitj/pydatastructs/pull/534) - This PR was built on the top of the above PR to add the Dinic algorithm for network flow.
53+
54+
- [#535](https://github.com/codezonediitj/pydatastructs/pull/535) - This PR
55+
closes the [issue-436](https://github.com/codezonediitj/pydatastructs/issues/436) by implementing a `test` function that helps in testing
56+
the library installation as well as supports submodule specific tests.
57+
58+
- [#537](https://github.com/codezonediitj/pydatastructs/pull/537) - This PR
59+
implements lower bound and upper bound in the BST data structure similar to
60+
CPP's STL.
61+
62+
**Phase 2**
63+
64+
- [#538](https://github.com/codezonediitj/pydatastructs/pull/538) - This PR closes an [issue-390](https://github.com/codezonediitj/pydatastructs/issues/390) on adding a `Multiset` data structure similar to CPP's STL.
65+
66+
- [#539](https://github.com/codezonediitj/pydatastructs/pull/539) - This PR
67+
adds Lazy Segment Tree implementation.
68+
69+
- [#540](https://github.com/codezonediitj/pydatastructs/pull/540) - This PR
70+
focuses on the CPP backend of the project targeting the sorting algorithm by starting with `bubble_sort`.
71+
72+
- [#542](https://github.com/codezonediitj/pydatastructs/pull/542) - This PR
73+
completed CPP backend of `selection_sort`.
74+
75+
- [#543](https://github.com/codezonediitj/pydatastructs/pull/543) - This PR
76+
completed CPP backend of `insertion_sort` and `is_ordered`.
77+
78+
- [#544](https://github.com/codezonediitj/pydatastructs/pull/544) - This PR
79+
extends CPP backend for search algorithms: `linear_search`, `binary_search`, and `jump_search`.
80+
81+
### Examples
82+
83+
1. Using the `test` function
84+
85+
```python
86+
>>> from pydatastructs import test
87+
>>> test(["graphs"])
88+
============================= test session starts ==============================
89+
platform darwin -- Python 3.8.16, pytest-7.3.1, pluggy-1.0.0
90+
rootdir: /Users/thebigbool/repos/pydatastructs
91+
plugins: cov-4.1.0, xdist-3.3.1, anyio-3.7.0
92+
collected 11 items
93+
94+
pydatastructs/graphs/tests/test_adjacency_list.py . [ 9%]
95+
pydatastructs/graphs/tests/test_adjacency_matrix.py . [ 18%]
96+
pydatastructs/graphs/tests/test_algorithms.py ......... [100%]
97+
98+
============================== 11 passed in 0.05s ==============================
99+
```
100+
101+
We can also test an imported submodule in the similar way:
102+
103+
```python
104+
>>> from pydatastructs import graphs
105+
>>> test([graphs])
106+
============================= test session starts ==============================
107+
platform darwin -- Python 3.8.16, pytest-7.3.1, pluggy-1.0.0
108+
rootdir: /Users/thebigbool/repos/pydatastructs
109+
plugins: cov-4.1.0, xdist-3.3.1, anyio-3.7.0
110+
collected 11 items
111+
112+
pydatastructs/graphs/tests/test_adjacency_list.py . [ 9%]
113+
pydatastructs/graphs/tests/test_adjacency_matrix.py . [ 18%]
114+
pydatastructs/graphs/tests/test_algorithms.py ......... [100%]
115+
116+
============================== 11 passed in 0.02s ==============================
117+
```
118+
119+
2. Using a `Multiset`
120+
121+
```python
122+
>>> from pydatastructs.miscellaneous_data_structures import Multiset
123+
>>> ms = Multiset()
124+
>>> ms.add(5)
125+
>>> ms.add(5)
126+
>>> ms.add(3)
127+
>>> ms.add(7)
128+
>>> len(ms)
129+
4
130+
>>> 5 in ms
131+
True
132+
>>> 2 in ms
133+
False
134+
```
135+
136+
3. Using a CPP backend
137+
138+
```python
139+
>>> from pydatastructs import OneDimensionalArray, Backend, linear_search
140+
>>> array = OneDimensionalArray(int, [1, 2, 5, 7, 10, 29, 40])
141+
>>> linear_search(array, 5, backend=Backend.CPP)
142+
2
143+
>>> linear_search(array, -5, backend=Backend.CPP) # not found
144+
>>>
145+
```
146+
147+
### Conclusion
148+
149+
This summer has been a great learning experience. I am grateful to my
150+
mentors, [Gagandeep Singh](https://github.com/czgdp1807), and [Smit Lunagariya](https://github.com/Smit-create) for always helping me with
151+
the new concepts, reviewing my PRs and providing quick responses.

0 commit comments

Comments
 (0)