This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
import time | |
class VillengardAlgorithm: | |
def __init__(self): | |
self.weapons_sold = 0 | |
self.casualty_rate = 0.01 # Initial minimal casualty rate | |
self.war = False | |
def check_for_war(self): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from math import log,exp | |
# Define site-specific parameters | |
#(e.g., soil type, location) | |
site_class = "A" # Site class: A, B, C, D, or E | |
latitude = 34.05 # Latitude of the site (in degrees) | |
longitude = -118.24 # Longitude of the site (in degrees) | |
return_period = 475 # Return period in years | |
# Define the GMPE coefficients for your chosen GMPE model | |
# These coefficients would be specific to the GMPE you are using |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ForEach($x in (Get-ChildItem -Filter *.png)){ffmpeg -i $x "jpg/$($x.Basename).jpg" } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Requires AutoHotkey v2.0-a | |
Run A_ComSpec ' /c "%windir%\explorer.exe shell:::{05d7b0f4-2121-4eff-bf6b-ed3f69b894d9}"' | |
Sleep 2000 | |
if WinExist("Notification Area Icons") | |
WinActivate ; Use the window found by WinExist. | |
ControlClick "Button3", "Notification Area Icons" | |
WinClose "Notification Area Icons" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argostranslate.package | |
import argostranslate.translate | |
from argostranslate.translate import translate, get_installed_languages | |
from_code = "en" | |
to_code = "es" | |
en, es = get_installed_languages() # [LanguageModel_English, LanguageModel_Spanish] | |
translator = es.get_translation(en) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import argostranslate.package | |
import argostranslate.translate | |
from_code = "en" | |
to_code = "es" | |
# Download and install Argos Translate package | |
argostranslate.package.update_package_index() | |
available_packages = argostranslate.package.get_available_packages() | |
package_to_install = next( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
For /f "tokens=2-4 delims=/ " %%a in ('date /t') do (set mydate=%%c-%%a-%%b) | |
For /f "tokens=1-2 delims=/:" %%a in ('time /t') do (set mytime=%%a%%b) | |
git add . | |
git commit -m "Autocommit %mydate%_%mytime%' | |
git push origin main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using CSiAPIv1; | |
using System; | |
using static Globals; | |
namespace ETABSPlugin | |
{ | |
public class cPlugin | |
{ |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
NewerOlder