Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/SioKCronin/nature-inspired-optimisation
/ functions
Functions
128 in github.com/SioKCronin/nature-inspired-optimisation
⨍
Functions
128
◇
Types & classes
27
↓ 10 callers
Method
update
Update the benchmark state (optimum position and radius). Should be called at the start of each optimization iteration to update the
nio/benchmarks.py:111
↓ 7 callers
Method
get_property
Get a property value for this soil type.
nio/iwd_co.py:119
↓ 5 callers
Method
initialise
Initialize the population of particles.
nio/ppso.py:102
↓ 5 callers
Method
step
Perform one optimization step. Args: iteration: Current iteration number (for adaptive exploration) max_itera
nio/ppso.py:265
↓ 4 callers
Method
_clamp_position
Clamp position within bounds.
nio/philippine_eagle.py:179
↓ 4 callers
Method
_gaussian_walk
Gaussian walk operator for local search.
nio/philippine_eagle.py:145
↓ 4 callers
Method
record_state
Record current state of algorithm for visualization.
nio/visualize_ca.py:75
↓ 3 callers
Method
_assign_streams
Assign streams to rivers or sea using roulette wheel selection.
nio/water_cycle.py:191
↓ 3 callers
Method
_levy_flight
Levy flight operator for exploration.
nio/philippine_eagle.py:129
↓ 3 callers
Method
create_animation
Run algorithm and create animation. Args: iterations: Number of iterations to run
nio/visualize_ca.py:107
↓ 3 callers
Method
get_property
Get a property value for this liquid type.
nio/water_cycle.py:88
↓ 3 callers
Method
initialise
Initialize the population of water drops.
nio/iwd_co.py:199
↓ 3 callers
Method
initialise
Initialize the population of water bodies.
nio/water_cycle.py:164
↓ 3 callers
Method
step
Perform one optimization step.
nio/iwd_co.py:340
↓ 3 callers
Method
step
Perform one optimization step.
nio/water_cycle.py:284
↓ 2 callers
Method
_calculate_knowledge_gain
Calculate knowledge gain at a given position. Higher knowledge gain indicates unexplored regions with potential for discoveri
nio/ppso.py:130
↓ 2 callers
Method
_clamp_position
Clamp position within bounds.
nio/cultural.py:262
↓ 2 callers
Method
_clip_position
(self, position: Vector)
nio/dragonfly.py:83
↓ 2 callers
Method
_dance_party
Dance party selection - the best dancer wins!
nio/cultural.py:345
↓ 2 callers
Method
_distance
(self, a: Sequence[float], b: Sequence[float])
nio/dragonfly.py:92
↓ 2 callers
Method
_evaporation_condition
Check if evaporation should occur (water is close to target). Boiling point affects the distance threshold - liquids with lower
nio/water_cycle.py:244
↓ 2 callers
Method
_flow_toward_target
Move water body toward target based on flow rate and liquid properties.
nio/water_cycle.py:224
↓ 2 callers
Method
_get_evaporation_rate
Get effective evaporation rate for a water body based on liquid type.
nio/water_cycle.py:262
↓ 2 callers
Method
_rain
Generate new water bodies through rain (random positions). Rain can have different liquid types based on distribution.
nio/water_cycle.py:267
↓ 2 callers
Method
_update_reactive_particle
Update a reactive particle using standard PSO.
nio/ppso.py:242
↓ 2 callers
Method
_update_sub_populations
Update sub-population groupings.
nio/philippine_eagle.py:113
↓ 2 callers
Function
example_html
Example creating interactive HTML visualization for browser.
examples/ca_visualization_example.py:64
↓ 2 callers
Function
rastrigin
Default benchmark function (global minimum at 0).
nio/bat.py:19
↓ 2 callers
Method
run
(self, iterations: int = 100)
nio/bat.py:145
↓ 2 callers
Method
run
Run the optimization algorithm for specified iterations.
nio/iwd_co.py:379
↓ 2 callers
Function
visualize_ca
Convenience function to create CA visualization. Args: bounds: Search space bounds (must be 2D) population_size: Population size
nio/visualize_ca.py:588
↓ 1 callers
Method
_accept
Select individuals to influence the belief space.
nio/cultural.py:154
↓ 1 callers
Method
_assign_operator
Assign operators to sub-populations in a round-robin fashion.
nio/philippine_eagle.py:108
↓ 1 callers
Method
_attractiveness
Calculate attractiveness based on distance. β(r) = β₀ * exp(-γ * r²) Args: distance: Euclidean
nio/firefly.py:93
↓ 1 callers
Method
_crossover
Crossover operator between current and another eagle.
nio/philippine_eagle.py:164
↓ 1 callers
Method
_crossover
Perform crossover between two parents.
nio/cultural.py:271
↓ 1 callers
Method
_determine_phase
Determine the current optimization phase.
nio/philippine_eagle.py:121
↓ 1 callers
Method
_distance
Calculate Euclidean distance between two positions.
nio/firefly.py:107
↓ 1 callers
Method
_exploration
Exploration phase update.
nio/philippine_eagle.py:207
↓ 1 callers
Method
_find_neighbors
(self, index: int, radius: float)
nio/dragonfly.py:105
↓ 1 callers
Method
_gaussian_knowledge_gain
Gaussian Process-inspired knowledge gain.
nio/ppso.py:146
↓ 1 callers
Method
_generate_html_content
Generate HTML content with embedded visualization using Plotly.
nio/visualize_ca.py:337
↓ 1 callers
Method
_influence
Generate new position influenced by belief space.
nio/cultural.py:227
↓ 1 callers
Method
_initialize_belief_space
Initialize the belief space with initial knowledge.
nio/cultural.py:134
↓ 1 callers
Method
_inverse_distance_knowledge_gain
Inverse distance-based knowledge gain.
nio/ppso.py:165
↓ 1 callers
Method
_levy_flight
(self)
nio/dragonfly.py:95
↓ 1 callers
Method
_local_optimization
Local optimization phase update.
nio/philippine_eagle.py:188
↓ 1 callers
Method
_local_search
(self, bat: Bat, best_position: Sequence[float])
nio/bat.py:100
↓ 1 callers
Method
_move
(self, bat: Bat)
nio/bat.py:89
↓ 1 callers
Method
_move
Move the water drop based on its velocity and update position.
nio/iwd_co.py:304
↓ 1 callers
Method
_move_particle
Move particle and apply bounds.
nio/ppso.py:252
↓ 1 callers
Method
_mutate
Apply mutation to a position.
nio/cultural.py:285
↓ 1 callers
Method
_perturbation
Perturbation operator for exploration.
nio/philippine_eagle.py:155
↓ 1 callers
Method
_predict_prey_position
(self, dragonfly: Dragonfly, prey_position: Vector, prey_velocity: Vector)
nio/dragonfly.py:115
↓ 1 callers
Method
_render_animation
Render the animation from recorded history.
nio/visualize_ca.py:126
↓ 1 callers
Method
_select_target
Select target position for the water drop. Combines attraction to best solution with exploration based on soil.
nio/iwd_co.py:319
↓ 1 callers
Method
_update_belief_space
Update belief space based on accepted individuals.
nio/cultural.py:163
↓ 1 callers
Method
_update_frequency
(self, bat: Bat)
nio/bat.py:82
↓ 1 callers
Method
_update_normative
Update normative knowledge from accepted individuals.
nio/cultural.py:174
↓ 1 callers
Method
_update_proactive_particle
Update a proactive particle using knowledge gain.
nio/ppso.py:179
↓ 1 callers
Method
_update_situational
Update situational knowledge with best individuals.
nio/cultural.py:208
↓ 1 callers
Method
_update_soil
Update soil content based on fitness improvement and material properties. Drops pick up soil from worse positions and deposit it at b
nio/iwd_co.py:267
↓ 1 callers
Method
_update_velocity
(self, bat: Bat, best_position: Sequence[float])
nio/bat.py:85
↓ 1 callers
Method
_update_velocity
Update velocity based on soil content, target position, and material properties. Velocity increases when moving toward areas with les
nio/iwd_co.py:228
↓ 1 callers
Method
create_html_visualization
Create an interactive HTML visualization that can be opened in a browser. Args: iterations: Number of iterations to run
nio/visualize_ca.py:299
↓ 1 callers
Function
example_custom
Example with custom algorithm configuration.
examples/ca_visualization_example.py:33
↓ 1 callers
Function
example_simple
Simple example using the convenience function.
examples/ca_visualization_example.py:17
↓ 1 callers
Function
example_with_custom_objective
Example with a custom 2D objective function.
examples/ca_visualization_example.py:81
↓ 1 callers
Function
hybrid_approach_example
Demonstrate a hybrid approach: use different algorithms in sequence. Strategy: 1. Start with PPSO for exploration (proactive particl
examples/algorithm_comparison.py:179
↓ 1 callers
Method
initialise
(self)
nio/dragonfly.py:71
↓ 1 callers
Method
initialise
Initialize the firefly population.
nio/firefly.py:81
↓ 1 callers
Method
initialise
(self)
nio/bat.py:67
↓ 1 callers
Method
initialise
Initialize the population and divide into sub-populations.
nio/philippine_eagle.py:88
↓ 1 callers
Method
initialise
Initialize population and belief space.
nio/cultural.py:118
↓ 1 callers
Function
main
()
nio/dragonfly.py:208
↓ 1 callers
Function
main
Example usage.
nio/visualize_ca.py:666
↓ 1 callers
Function
main
Example usage of the PPSO algorithm.
nio/ppso.py:329
↓ 1 callers
Function
main
Example usage of the Firefly Algorithm.
nio/firefly.py:196
↓ 1 callers
Function
main
()
nio/__main__.py:27
↓ 1 callers
Function
main
()
nio/bat.py:160
↓ 1 callers
Function
main
Example usage of the Philippine Eagle Optimization algorithm.
nio/philippine_eagle.py:279
↓ 1 callers
Function
main
Example usage of the IWD-CO algorithm.
nio/iwd_co.py:396
↓ 1 callers
Function
main
Example usage of the Water Cycle Algorithm.
nio/water_cycle.py:390
↓ 1 callers
Function
main
Example usage of the Cultural Algorithm.
nio/cultural.py:368
↓ 1 callers
Function
main
Main comparison example.
examples/algorithm_comparison.py:275
↓ 1 callers
Function
parse_args
()
nio/__main__.py:14
↓ 1 callers
Function
plot_convergence_comparison
Plot convergence curves for all three algorithms.
examples/algorithm_comparison.py:117
↓ 1 callers
Function
print_comparison_summary
Print a summary comparison of the algorithms.
examples/algorithm_comparison.py:151
↓ 1 callers
Method
run
(self, iterations: int = 100)
nio/dragonfly.py:193
↓ 1 callers
Method
run
Run the optimization algorithm for specified iterations.
nio/ppso.py:311
↓ 1 callers
Method
run
Run the Firefly Algorithm optimization. Args: iterations: Number of iterations to run Returns:
nio/firefly.py:172
↓ 1 callers
Method
run
Run the optimization algorithm for specified iterations.
nio/philippine_eagle.py:262
↓ 1 callers
Method
run
Run the optimization algorithm for specified iterations.
nio/water_cycle.py:373
↓ 1 callers
Method
run
Run the optimization algorithm for specified iterations.
nio/cultural.py:351
↓ 1 callers
Function
run_algorithm_comparison
Compare PPSO, IWD-CO, and Water Cycle Algorithm on the same problem.
examples/algorithm_comparison.py:25
↓ 1 callers
Method
step
(self, iteration: int, total_iterations: int)
nio/dragonfly.py:123
↓ 1 callers
Method
step
Perform one iteration of the Firefly Algorithm.
nio/firefly.py:112
↓ 1 callers
Method
step
(self)
nio/bat.py:106
↓ 1 callers
Method
step
Perform one optimization step.
nio/philippine_eagle.py:234
↓ 1 callers
Method
step
Perform one iteration of the Cultural Algorithm.
nio/cultural.py:297
next →
1–100 of 128, ranked by callers