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
$destinationFolder = "$Env:userprofile\desktop\lockscreenimages" | |
$lockScreenImageStore = "$Env:userprofile\AppData\Local\Packages\Microsoft.Windows.ContentDeliveryManager_cw5n1h2txyewy\LocalState\Assets" | |
$File = Get-ChildItem -Path "$lockScreenImageStore" -Recurse | |
if (!(Test-Path -path $destinationFolder)) {New-Item "$destinationFolder" -Type Directory} | |
for($i = 0; $i -lt $File.Count; $i++) | |
{ | |
Copy-Item -Force $File[$i].FullName ("$destinationFolder\" + $File[$i].BaseName + $i +".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
(function () { | |
$(function () { | |
/*I add the ui elements I need here. I thought it would be better put them in here at runtime rather than hard code them in the index.html in case the index.html from my version of swashbuckle is made obsolete in a future version of the package. */ | |
var hmacAuthUi = | |
' | |
<div class="input"><label for="input_api_username">Api Username: </label><input placeholder="Api Username" id="input_api_username" name="input_api_username" type="text" size="20"></div> | |
' + | |
' | |
<div class="input"><label for="input_api_hmackey">Api Key: </label><input placeholder="ApiKey" id="input_api_hmackey" name="input_api_hmackey" type="text" size="20"></div> |
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
.EnableSwaggerUi(c=> | |
{ | |
c.InjectStylesheet(assemblyType, "Api.SwaggerExtensions.swaggeroverrides.css"); | |
c.InjectJavaScript(assemblyType, "Api.SwaggerExtensions.hmac-sha1.js"); | |
c.InjectJavaScript(assemblyType, "Api.SwaggerExtensions.moment.js"); | |
c.InjectJavaScript(assemblyType, "Api.SwaggerExtensions.enc-base64.js"); | |
c.InjectJavaScript(assemblyType, "Api.SwaggerExtensions.sha256.js"); | |
c.InjectJavaScript(assemblyType, "Api.SwaggerExtensions.apihmacheaderauth.js"); |
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 java.nio.charset.StandardCharsets; | |
import java.security.SignatureException; | |
import java.security.spec.EncodedKeySpec; | |
import com.eviware.soapui.support.types.StringToStringMap; | |
import javax.crypto.Mac; | |
import javax.crypto.spec.SecretKeySpec; | |
import java.io.UnsupportedEncodingException; | |
import java.security.MessageDigest; | |
import javax.xml.bind.DatatypeConverter; | |
import java.sql.Date.*; |
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
batch_size=64 | |
no_of_epochs=1 | |
# do it | |
vgg = Vgg16() | |
# Grab a few images at a time for training and validation. | |
# NB: They must be in subdirectories named based on their category | |
train_batches = vgg.get_batches(train_path, batch_size=batch_size) | |
val_batches = vgg.get_batches(valid_path, batch_size=batch_size*2) | |
vgg.finetune(train_batches) | |
vgg.model.optimizer.lr = 0.01 |
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
npm install -g create-react-app | |
create-react-app my-app | |
cd my-app | |
git init | |
heroku create -b https://github.com/mars/create-react-app-buildpack.git | |
git add . | |
git commit -m "react-create-app on Heroku" | |
git push heroku master | |
heroku open |
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
{ | |
"root": "build/", | |
"clean_urls": false, | |
"routes": { | |
"/**": "index.html" | |
} | |
} |
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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions | |
// - XState (all XState exports) |
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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions | |
// - XState (all XState exports) |
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
function numberToSocial(bigNum, startAt = 10_000) { | |
return bigNum < startAt ? bigNum : Intl.NumberFormat("en", { | |
notation: "compact", | |
style: "decimal", | |
maximumFractionDigits: 1, | |
roundingMode: "floor", | |
unitDisplay: "narrow", | |
}).format(bigNum) | |
} |
OlderNewer