I trained resnet50 recently on imagenet1k which you can read about here:
blog: https://medium.com/@rraushan24/training-resnet-50-from-scratch-lessons-beyond-the-model-4b96fa23f799
github: https://github.com/Rakesh-Raushan/trainining_resnet50_from_scratch_on_imagenet1k
Sometimes option disk.partition.size in Android device manager should be decreased . Happened to me once when my disk size was too low and my disk.partition.size was under that size
I ran into the same issue and it was because the test project referenced another project that had the xunit.extensibility.core as a dependency. Reworking this so only the top-level test project had references to any xunit assemblies fixed it.
I posted a BUG report on the pylon repo for this, but since then I can't reproduce the issue above anymore.
For more details, see the bug report.
Given that I don't know the cause, I have no guarantee that it will keep working now. Therefore, any additional information related to this issue is welcomed!
I am also facing the same issue and below is the complete code i am using in JMeter tool-
import com.mongodb.MongoClient;
import com.mongodb.MongoCredential;
import com.mongodb.ServerAddress;
import com.mongodb.client.MongoCollection;
import com.mongodb.client.MongoDatabase;
import org.bson.Document;
import org.bson.types.ObjectId;
import static com.mongodb.client.model.Filters.*;
import static com.mongodb.client.model.Updates.*;
// MongoDB connection details
def serverAddress = new ServerAddress(vars.get("mongoHost"), vars.get("mongoPort").toInteger())
// MongoDB credential information
def username = vars.get("mongoUsername");
def databasename = vars.get("mongoDatabase");
def password = vars.get("mongoPassword").toCharArray()
def credentials = MongoCredential.createCredential(username, databasename, password)
// Create MongoClient
def mongoClient = new MongoClient(serverAddress, [credentials] as List)
// Connect to the database
def database = mongoClient.getDatabase(databasename)
// Access a collection
def collection = database.getCollection(vars.get("mongoCollection"))
// Document to find
Document result = collection.find(eq("email", vars.get("mail"))).first();
//Document result = collection.await collection.find({});
if (result != null)
{
// Document to update
//insertOne
collection.updateOne(eq("email", vars.get("randomEmail")),combine(set("isActive", true)));
return "User with email=" + vars.get("email") + " modified";
//return result;
}else
{
return "No Record Found";
}
// Close MongoDB connection
mongoClient.close()
**error message-**
Response code:500
Response message:javax.script.ScriptException: com.mongodb.MongoTimeoutException: Timed out after 30000 ms while waiting to connect. Client view of cluster state is {type=UNKNOWN, servers=[{address=mongo --host effie-sharedperf-docdb.cluster-cpmjeylhxh2g.us-east-1.docdb.amazonaws.com:27017, type=UNKNOWN, state=CONNECTING, exception={com.mongodb.MongoSocketException: mongo --host effie-sharedperf-docdb.cluster-cpmjeylhxh2g.us-east-1.docdb.amazonaws.com}, caused by {java.net.UnknownHostException: mongo --host effie-sharedperf-docdb.cluster-cpmjeylhxh2g.us-east-1.docdb.amazonaws.com}}]
SampleResult fields:
ContentType:
DataEncoding: null
Not all EU States give a full answer, you might be interested in the PHP/Curl example i wrote with all the VIES REST API parameters explained.
Same problem (and solution) for any plugin package, for example melos. Problem occurs when upgrading/downgrading flutter. Package activated within different flutter version should be deactivated/activated again.
flutter upgrade
...
flutter pub global deactivate melos
flutter pub global activate melos
For me it deleted the shared preferences, when I force installed an older app version (with lower build number) with the same app id. This probably doesn't affect published builds, as newer versions need to have a higher build number.
did you manage to solve it? I have the same problem
I am facing the same issue as well..I am going to provide my code and if someone who understands this problem, please help out. This has been this way since I started using Algolia.. for almost two years now.. I can never solve this issue.
here is lazy load class
class LazyLoadShortlists {
const LazyLoadShortlists(
this.alogliaShortlist, this.pageKey, this.nextPageKey);
final List<MdlShortlistAlgolia> alogliaShortlist;
final int pageKey;
final int? nextPageKey;
factory LazyLoadShortlists.fromResponse(SearchResponse response) {
final items = response.hits.map(MdlShortlistAlgolia.fromJson).toList();
final isLastPage = response.page >= response.nbPages;
final nextPageKey = isLastPage ? null : response.page + 1;
return LazyLoadShortlists(items, response.page, nextPageKey);
}
}
And here is my api call for Algolia
class AllShortlistRepository {
/// Component holding search filters
final filterState = FilterState();
// setup a page that display houseDatabase
final PagingController<int, MdlShortlistAlgolia> pagingController =
PagingController(firstPageKey: 0);
final searchTextController = TextEditingController();
// search houses in Algolia Database
final shortlistDatabase = HitsSearcher.create(
applicationID: AlgoliaCredentials.applicationID,
apiKey: AlgoliaCredentials.apiKey,
state: const SearchState(
indexName: AlgoliaCredentials.shortlistIndex,
numericFilters: ["createdTime >= 0"],
hitsPerPage: 10,
),
);
late final _agentNameFacet = shortlistDatabase.buildFacetList(
filterState: filterState, attribute: 'agentName');
late final _pinShortlistFacet = shortlistDatabase.buildFacetList(
filterState: filterState, attribute: 'pinShortlist');
AllShortlistRepository() {
shortlistDatabase.connectFilterState(filterState);
displayPropertiesOnThePage.listen((page) {
if (page.pageKey == 0) {
pagingController.refresh();
}
pagingController.appendPage(page.alogliaShortlist, page.nextPageKey);
}).onError((error) {
pagingController.error = error;
});
// this loads the list of house sucessfully properly when its enabled, but search does not work anymore
// but, when this disable, the search works, but it does not load the list of houses anymore
pagingController.addPageRequestListener((pageKey) =>
shortlistDatabase.applyState((state) => state.copyWith(page: pageKey)));
// pagingController.addPageRequestListener((pageKey) {
// shortlistDatabase.applyState((state) => state.copyWith(
// page: pageKey,
// ));
// });
filterState.filters.listen((_) => pagingController.refresh());
}
/// Get buyer list by query.
// void search(String query) {
// pagingController.refresh();
// shortlistDatabase.query(query);
// }
void search(String query) {
pagingController.refresh(); // Reset the PagingController state
shortlistDatabase.applyState((state) => state.copyWith(
query: query,
page: 0, // Reset to the first page to ensure a fresh search
facetFilters: [
'createdTime:${DateTime.now().millisecondsSinceEpoch}'
],
));
}
Future<List<ShortlistQuerySuggestion>> searchWithTypeAhead(
String query) async {
pagingController.refresh();
shortlistDatabase.query(query);
return suggestions.first;
}
// get stream of properties
Stream<LazyLoadShortlists> get displayPropertiesOnThePage =>
shortlistDatabase.responses.map(LazyLoadShortlists.fromResponse);
/// Get stream of search result, like the number of the properties
Stream<SearchMetadata> get searchMetadata =>
shortlistDatabase.responses.map(SearchMetadata.fromResponse);
// get stream of agentName
Stream<List<SelectableFacet>> get agentName => _agentNameFacet.facets;
// toggle agentName
void toggleAgentName(String agentName) {
pagingController.refresh();
_agentNameFacet.toggle(agentName);
}
/// Get stream of list of pinShortlist facets
Stream<List<SelectableFacet>> get priceRangeFacets =>
_pinShortlistFacet.facets;
/// Toggle selection of a priceRange facet
void togglePinShortlist(String pinShortlist) {
pagingController.refresh();
_pinShortlistFacet.toggle(pinShortlist);
}
/// Clear all filters
void clearFilters() {
pagingController.refresh();
filterState.clear();
}
Stream<List<ShortlistQuerySuggestion>> get suggestions =>
shortlistDatabase.responses.map((response) =>
response.hits.map(ShortlistQuerySuggestion.fromJson).toList());
/// Replace textController input field with suggestion
void completeSuggestion(String suggestion) {
searchTextController.value = TextEditingValue(
text: suggestion,
selection: TextSelection.fromPosition(
TextPosition(offset: suggestion.length),
),
);
}
/// In-memory store of submitted queries.
final BehaviorSubject<List<String>> _history =
BehaviorSubject.seeded(['jackets']);
/// Stream of previously submitted queries.
Stream<List<String>> get history => _history;
/// Add a query to queries history store.
void addToHistory(String query) {
if (query.isEmpty) return;
final _current = _history.value;
_current.removeWhere((element) => element == query);
_current.add(query);
_history.sink.add(_current);
}
/// Remove a query from queries history store.
void removeFromHistory(String query) {
final _current = _history.value;
_current.removeWhere((element) => element == query);
_history.sink.add(_current);
}
/// Clear everything from queries history store.
void clearHistory() {
_history.sink.add([]);
}
/// Dispose of underlying resources.
void dispose() {
shortlistDatabase.dispose();
}
}
It also happens, if you force install an old app version (lower build number) on top of the current one.
try add a SPACE before the tag containing the "not highlighted" javascript...
Atm. it is not possible to enable both. Or at least, vertical scrolling behaviour will override horizontal scrolling.
I just created a PR implementing both ways of scrolling at the same time by defining a switch-key to be pressed analogue to the zoomKey
.
Give it a look: https://github.com/visjs/vis-timeline/pull/1852
I found a solution myself.
const GifCard = ({
gif,
onClick
}: {
gif: Gif;
onClick: (gif: Gif) => void;
}) => {
const [isLoading, setIsLoading] = useState(true);
return (
<>
<Skeleton
w="100%"
maw={160}
radius="xs"
aria-label="gif skeleton"
h={gif.media_formats.gif.duration > 3 ? 160 : 90}
style={{ display: isLoading ? 'block' : 'none' }}
/>
<Image
src={gif.media_formats.gif.url}
w="100%"
maw={160}
radius="xs"
alt="GIF"
onLoad={() => setIsLoading(false)}
style={{ display: isLoading ? 'none' : 'block' }}
onClick={() => onClick(gif)}
/>
</>
);
};
Ljudi ja sam toliko odletio u visine, da pojma nema sta jec sve, mislim čak da sam i umro, ali vidim da je tako ni loše na drugom svijetu, da jeste inače bi se neko dosad vratio 😇😇😂😂😂😂😂źvajz
this question is quite old, but I have the same issue at the moment and didn't find another way to silence it.
IMHO an ideal solution would be a compiler option where you can provide the the minimal compiler version that your code is compiled with. This should silence (irrelevant) ABI infos involving older compilers but still shows relevant infos.
I would like to suggest this to the gcc developers but I don't see a way to do that: I cannot create a bugzilla account, because it is not possible automatically and an email request bounces.
Navigate to the Build Phases tab of your target. Locate the Run Script phase that's triggering the warning. add this line in 'touch "${BUILT_PRODUCTS_DIR}/generated_file.txt"' Build Phase run script
In the Output Files section, click the + button to add paths to the files your script '$(BUILT_PRODUCTS_DIR)/generated_file.txt'
I have worked on many OCR architectures. I have even trained ANPR for 24 different European languages and ANPR for India. Basically there is no pre-trained recognizer for OCR of license plates. You need to train a model for that. You can choose multiple OCR architectures and see which one is the best for your application. For training the OCR model, you need to first prepare a dataset of license plate images. You can scrape online images, crop them from CCTV cameras on roads, label them manually or from OCR service like amazon or google and create a good quality dataset.
In your symfony projects directory (Using Command Line)
For shorter details
php bin/console --version
For Details (e.g. Symfony & PHP versions, Log directory, End of Life.... )
php bin/console about
Use this plugin to add JUnit 5 compatibility to your project: id(“de.mannodermaus.android-junit5”) version “1.10.0.0”
var configFolder = Path.Combine(Directory.GetCurrentDirectory(), "Configs");
foreach (var file in Directory.GetFiles(configFolder, "*.ocelot.json")) { builder.Configuration.AddJsonFile(file, optional: true, reloadOnChange: true);enter image description here }
use [email protected] its the stable code with it working fine.
import in your app module.ts -> NgxSkeletonLoaderModule.forRoot(), and in your html ->
Getting the same error , following...
I am having a similar problem. I have found a way to fix my problem but it involves some manual changes to the RESX file. Try doing a global search of your entire solution for the item name you added to resources.
When I add resources in this new editor, I add them to RESOURCEs in the options panel as you showed above. I then had to manually change the RESX file.
<data name="Shopping" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>My Project\Resources\Shopping.txt;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
Note the start of the clause. I added '..\' (dot dot backslash) ahead of the 'My Project' part of that. I presume that changed the reference to relative.
I had a further problem you can also see in the line. My addition was generated as a .Byte[] array even though I specified it as a Text File. All of my old references were generated as System.String. I had to change this in the RESX file entries. This is definitely a change from the old editor and it is very confusing.
My initial problem was very much like what you described. When I tried to access my added resource using My.Resources("xxxxx"), it did not work until I got the file moved into proper location. I did a lot of things to get this resolved. So many that I am not sure which one actually did the trick. I believe I did it using a drag/drop or a copy/paste in solution explorer.
Then I had the problem with it being added as a byte array. I adapted by programmatically changing the byte array to a string when I read it, then I figured out how to modify the definitions in the RESX file to be string.
<data name="BaseDropCategories" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>..\Resources\BaseDropCategories.txt;System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
and
Friend ReadOnly Property BaseDropCategories() As String
Get
Return ResourceManager.GetString("BaseDropCategories", resourceCulture)
End Get
End Property
I had enough old references in my RESX file to refer to to get the entry right. (Be careful modifying your RESX file!!)
I am still processing what I've done and I experimented on another program that has no resources without success. I still would like to know WHY things now work the way they do, but I suspect some of what I did you may find usable. My additions in this program show up in the grid in the MS Resource Editor screen but are inaccessible in the only way I know at present to access it in code.
Escape the value with addcslashes:
$orConstraints = [];
$orConstraints[] = $query->like('productname', '%' . addcslashes($name, '_%') . '%');
$orConstraints[] = $query->like('tradename','%' . addcslashes($name, '_%') . '%');
You need to determine if the request to stop/start the VM actually reaches ARM and the CRP, Whatever runbook being used, ultimately a request to start/stop the VM will be sent first to ARM and onto the CRP.
The command below can be used to start a VM.
Start-AzVM -ResourceGroupName "ResourceGroup11" -Name "VirtualMachine07"
Your connection String should be like this: pyodbc.connect('DRIVER=' + driver +';SERVER=' + server +';PORT=1433' +';DATABASE=' + database +';UID=' + uid +';PWD='+ pwd + 'TrustServerCertificate=yes')
Processing algorithms are on a separate thread than QgsInterface. Accessing interface (QgsProject.instance()) from a processing algorithm works poorly and often make Qgis crash.
You should return the layer in a sink at the end of the algorithm.
I faced same issue , This is beacuse you use in bottoom navigation resizeToAvoidBottomInset: false, just remove this line from bottom navigation its work fine .
maybe a bit too late; I was faced with the same issue and the following command ensured that the tags were pushed to bitbucket cloud;
git push origin --tags
I found out the answer that is to set autoSend: false in the Generative answer kind: SearchAndSummarizeContent of the code editor. Hope that helps anyone with similar issues.
just change '@/components/HelloWorld.vue' to './components/HelloWorld.vue' change the "@" to "."
You can use a uri like this: smsto:012345678;09876523
. Seperate the numbers using ;
Finally, I found a solution to this.
As of date, it is not possible to match on a "substring" in Istio's AuthorizationPolicy
. You can either match with a prefix (e.g "abc*") or suffix ("*abc") but not something in the middle (e.g * abc *).
To solve this, I used an envoyFilter
to generate a custom header which only contains the exact header value to match against and then used the same in the AuthorizationPolicy
.
Starting an activity from background or foreground services is no longer allowed. It has been like this since Android 10.
https://developer.android.com/guide/components/activities/background-starts
I tried to execute it using your bash, but the status code returned was 403
embed = {
"description": f"**TEST Notification** <:blackops:1327144166131630192>",
"color": 0xa020f0, # Replace with the desired color
}
self.discord.post(embeds=[embed])
Instead of using the ID format directly, use the format <:name:id> for non-animated emojis
My issue is also similar even after downloading all these
nltk.download('punkt')
nltk.download('wordnet')
nltk.download('omw-1.4')
It was resolved by-
text = "Finally my issue of nltk is resolved"
tokens = word_tokenize(text,language='english', preserve_line=True)
hello sir can u share your code how u r ingesting pdf. Do u have any github link about your project. I want analyz your project
The error occurs because of a version mismatch between one of your dependencies and flutter_inappwebview. The issue specifically appears in iOS builds with the error.
@nicholas_randall is correct. Update your pubspec.yaml to use the correct version of flutter_inappwebview:
flutter_inappwebview: ^6.1.0+1
Then run:
flutter clean
flutter pub get
cd ios
pod install
Why This Works:
pod install
updates the iOS native dependencies to match the new version.If you're still having issues after updating, you might need to:
pod deintegrate
in the iOS directoryThis ensures a completely clean installation of the updated dependencies.
S3 will not check if the requesting people are logged into their AWS accounts. Instead, the request must use one of the authentication methods.
If you want to share links that can be opened in a browser, pre-signed URLs are usually a good way to go. However, they expire after a maximum expiration time of 7 days. If you want longer expiration times, Cloudfront has more options to share content from S3 buckets securely.
I'm using Xcode 16 and the runtimes are now being stored in /Library/Developer/CoreSimulator/Volumes/
instead:
Thank you for all your effort. I found the answer: Use htmx:confirm
instead of hx-on:submit
:
<form id="assessment" name="assessment"
hx-post="/assessment-result.php"
hx-target=".questions_list"
hx-swap="outerHTML transition:true swap:200ms"
hx-trigger="submit"
hx-include=".questions_list input[type=radio]:checked">
...
</form>
document.body.addEventListener('htmx:confirm', (event) => {
event.preventDefault();
if( invalid ) {
swal('Invalid form');
}else{
// https://htmx.org/events/#htmx:confirm
// true to skip the built-in window.confirm()
event.detail.issueRequest(true);
}
});
To add upon dave.c's answer, you'll need the pooled-jms package for the pool to instantiate.
implementation("org.messaginghub:pooled-jms:3.1.7")
Try use ClassCleanupBehavior.EndOfClass
in your ClassCleanup attribute.
In my case, changing GOROOT
from /usr/local/go/
to /usr/lib/go/
, remove the problem.
My output of go tool
is:
$ go tool
addr2line
asm
buildid
cgo
...
Instead of:
$ go tool
go: no tool directory: open /usr/share/go/pkg/tool/linux_amd64: no such file or directory
Maybe it will fix your problem too.
The previous comment: "pip install "cython<3.0.0" && pip install --no-build-isolation pyyaml==5.4.1" works for me
If you encounter problems like this that are connected to a wrong sequence of you running your code cells restarting the kernel and running the cells again in correct order is in most cases good advice.
You can restart your kernel by pressing the 0
key on your keyboard twice.
Downgrading the version to this work for me:
!pip install tensorflow==2.14 tensorflow-hub==0.15
To run individual Gradle test in command line,
$ gradle test --tests "com.package.className.testMethodName"
Bro you got the solution for this?
For a taxi service MySQL database design, you should consider the following key tables:
Customers Table: Store customer information (ID, name, contact details, etc.). Drivers Table: Store driver details (ID, name, license number, vehicle details, etc.). Vehicles Table: Store vehicle details (ID, make, model, license plate, driver ID). Rides Table: Store ride details (ride ID, customer ID, driver ID, vehicle ID, pickup/drop-off locations, ride status, date/time, fare). Bookings Table: For pre-booked rides (booking ID, customer ID, driver ID, vehicle ID, scheduled time, status). Payments Table: Store payment information (payment ID, ride ID, amount, payment method, payment status). This structure helps maintain clear relationships between customers, drivers, vehicles, and rides while supporting operations like booking, payment processing, and tracking.
For professional help in designing and implementing this MySQL database for your taxi service, feel free to contact Umrah Cab Service. We offer tailored database solutions for efficient operations.
Environment Details: CopyCUDA: 11.8 PyTorch: 2.3.1
Machine 1:
Machine 2:
Let's say B (2nd row in your plot) is nested within A (first row) and C (third row) and B are crossed. Then I'd use this model:
Y ~ B/A + C * (B/A)
You first specify that B is nested within A, then the 2nd summand tells R that additionally, C should be crosse with B nested within A.
import sys
sys.path.append("/usr/lib/python3/dist-packages")
sys.path.append("/usr/lib/libreoffice/program")
# Инициализируем окружение UNO
import uno
# Импортируем необходимые компоненты
from com.sun.star.text.ControlCharacter import PARAGRAPH_BREAK
from com.sun.star.text import XTextContent
from com.sun.star.beans import PropertyValue
Hello am facing an issue in my facebook developer console, am adding my apple store application ID and its a valid one that goes by https://apps.apple.com/us/app/fudchef/id1598786433 but am getting a return error mentioning invalid ID i have also added it as https://apps.apple.com/us/app/fudchef/id1598786433?platform=iphone still showing invalid. my app has been on apple store for 3 years. Kindly advise what to do.
__global__ void run_on_gpu(int* dev_ptr, size_t size) {
for (size_t i = 0; i < size; i++) {
printf("%d", dev_ptr[i]);
atomicAdd((int*)(dev_ptr + i), 1);
}
This can be achieved as of version 0.15.0 by not supplying a name when calling add_typer
. Source.
main.py
import typer
import other
app = typer.Typer()
app.add_typer(other.app)
other.py
import typer
app = typer.Typer()
@app.command()
def foo():
pass
number one: make sure you use latest versions of node and npm. number two: install each package separately to find out which one causes the error and then troubleshoot from there.
Also clear npm cache as you do the above steps
What you can also do is delete your node_modules folder and start over by installing one package at a time
Since DBeaver version 24.3 (pic. 2), search dialog was redesigned (pic.1). Since then there is no need to change search direction, so far as this behaviour assigned to shortcut(hot key).
Hope this info would be useful for someone else =)
sudo supervisorctl stop all
sudo supervisorctl reread
sudo supervisorctl update
sudo supervisorctl start all
php artisan queue:restart
Worked for me.
Is it possible we can send hyperlink through mms not with sms
After exploring the issue further, I found a working solution that builds on the suggestion provided by Alma_Matters. Thank you for pointing me in the right direction!
Here’s the updated and improved code:
/**
* Adds a logo to an image.
* The logo size is set to 20% of the smaller dimension of the base image.
* The page size is adjusted to match the image dimensions to avoid empty margins.
*
* @param {Blob} imageBlob - The base image.
* @param {Blob} logoBlob - The logo image.
* @return {{width: number, height: number}} A merged image blob with the logo.
*/
function addLogoToImage(imageBlob, logoBlob) {
// Get the image size
const size = getSize(imageBlob),
width = size.width,
height = size.height;
// Create a slide with the same dimensions as the image
const slides = DocsServiceApp.createNewSlidesWithPageSize({
title: 'temp',
parent: Drive.Files.get("root").id,
width: { unit: "pixel", size: width },
height: { unit: "pixel", size: height }
});
// Calculate the logo size (20% of the smaller dimension)
const minimumSize = Math.min(width, height) * 0.2;
// Access the slide
const presentation = SlidesApp.openById(slides);
const slide = presentation.getSlides()[0];
// Add the base image
slide.insertImage(imageBlob);
// Add the logo
slide.insertImage(logoBlob, 10, 10, minimumSize, minimumSize);
// Save and close the presentation
presentation.saveAndClose();
// Export the slide as an image
const response = UrlFetchApp.fetch(`https://docs.google.com/presentation/d/${slides}/export/png`, {
headers: {
Authorization: `Bearer ${ScriptApp.getOAuthToken()}`,
},
});
// Retrieve the merged image as a blob
const mergedImage = response.getBlob();
// Delete the temporary presentation
Drive.Files.remove(slides);
return mergedImage;
}
/**
* Retrieves the dimensions of an image blob.
* Based on code from ImgApp (https://github.com/tanaikech/ImgApp).
* Copyright (c) 2018 Tanaike.
* Licensed under the MIT License (https://opensource.org/licenses/MIT).
*
* @param {Blob} blob - The image blob to analyze.
* @return {{width: number, height: number}} An object containing the width and height of the image.
*/
function getSize(blob) {
const docfile = Drive.Files.create({
title: "size",
mimeType: "application/vnd.google-apps.document",
}).id;
const img = DocumentApp.openById(docfile).insertImage(0, blob);
Drive.Files.remove(docfile);
return { width: img.getWidth(), height: img.getHeight() };
}
saveAndClose()
to finalize the changes before exporting the image.For this code to work properly, the DocsServiceApp library, as well as Slides and Drive services must be installed in AppsScript.
This updated code resolves the issue while ensuring the output image is clean and properly formatted.
Example of using the code:
function test() {
var imageBlob = UrlFetchApp.fetch("https://......jpg").getBlob();
var logoBlob = UrlFetchApp.fetch("https://.......png").getBlob();
const mergedImage = addLogoToImage(imageBlob, logoBlob);
DriveApp.createFile(mergedImage);
}
Disclosure: I created this code and wrote this answer myself. Since I'm not fluent in English, I used GPT to help me refine the language and ensure clarity. The ChatGPT did not touch on the content of the code itself, only the translation of the answer into English.
echo -e "o\n1" | ./your_script.sh
The -e flag enables interpretation of backslash escapes (like \n for newline)
you can simulate the above behavior with a simple script and confirm if it works in your environment
It is worked well for me
sudo /Applications/XAMPP/xamppfiles/bin/apachectl start
Apache UI automatically turned up to status running
o with specific devices. The only hint I have is that one of the devices it occurred on was a Nexus 7.
NOTE: This is not the same problem as the similar-named question by me. The other question was due to trying to use the canvas before it was available, whereas here it was available.
Below is a sample of my code:
public class GameView extends SurfaceView implements SurfaceHolder.Callback { class GameThread extends Thread { @Override public void run() { while (running) { Canvas c = null; try { c = mSurfaceHolder.lockCanvas();
synchronized (mSurfaceHolder)
{
long start = System.currentTimeMillis();
doDraw(c);
long diff = System.currentTimeMillis() - start;
if (diff < frameRate)
Thread.sleep(frameRate - diff);
}
} catch (InterruptedException e)
{
}
finally
{
if (c != null)
{
mSurfaceHolder.unlockCanvasAndPost(c);
}
}
}
}
}
public void surfaceCreated(SurfaceHolder holder)
{
if (gThread.getState() == Thread.State.TERMINATED)
{
gThread = new GameThread(getHolder(), getContext(), getHandler());
gThread.start();
}
else
{
gThread.start();
}
}
}
I'm trying to display a custom SwiftUI view inside ARKit in a 3D scene as a texture on a plane. My view contains a blurred image and a translucent effect, but I am facing issues with getting the SwiftUI view to show correctly in the AR scene. Here is what I have so far:
I created a custom SwiftUI view, CustomBlurTranslucentView, which includes an image and some opacity and blur effects. I rendered the SwiftUI view to an image (UIImage), then converted it into a texture for the ARView. I am using this rendered image as a texture on a 3D plane entity in ARKit. However, I am unable to get it to display as intended and have some concerns regarding the image rendering part, since the image is generated from a UIView and not an actual ImageView component. Here’s the code I’m using:
// Anchor and plane creation
let anchor = AnchorEntity(world: [0, 0, -1])
// Create a custom SwiftUI view and convert it to a texture
let swiftUIView = CustomBlurTranslucentView()
let modelEntity = createPlaneEntity(from: swiftUIView, size: CGSize(width: 200, height: 100))
// Add the model entity to the anchor
anchor.addChild(modelEntity)
// Add the anchor to the AR scene
arView.scene.addAnchor(anchor)
// Function to create a plane entity with the custom view texture
private func createPlaneEntity(from view: some View, size: CGSize) -> ModelEntity {
let image = renderImage(from: view, size: size) // Render the SwiftUI view to an image
let adjustedImage = image.adjustOpacity(opacity: 0.4) // Adjust opacity of the rendered image
let texture = try! TextureResource(image: adjustedImage.cgImage!, options: .init(semantic: .none))
var material = UnlitMaterial()
material.baseColor = MaterialColorParameter.texture(texture)
let planeMesh = MeshResource.generatePlane(width: Float(size.width / 1000), height: Float(size.height / 1000))
let planeEntity = ModelEntity(mesh: planeMesh, materials: [material])
return planeEntity
}
// Function to render a SwiftUI view as a UIImage
private func renderImage(from view: some View, size: CGSize) -> UIImage {
let hostingController = UIHostingController(rootView: view)
hostingController.view.bounds = CGRect(origin: .zero, size: size)
hostingController.view.backgroundColor = .clear
let renderer = UIGraphicsImageRenderer(size: size)
return renderer.image { _ in
hostingController.view.drawHierarchy(in: hostingController.view.bounds, afterScreenUpdates: true)
}
}
// Custom SwiftUI view with blur and opacity
struct CustomBlurTranslucentView: View {
var body: some View {
ZStack {
Image("photo5") // Replace with your image
.resizable()
.scaledToFill()
.edgesIgnoringSafeArea(.all)
.blur(radius: 15)
.opacity(0.3)
VStack {
Text("Custom Under Effect")
.font(.headline)
.foregroundColor(.white)
.padding()
}
}
}
}
In ARKit with SwiftUI, it's a bit tricky to display a custom SwiftUI view as a texture on a 3D object, since ARKit generally works with textures created from UIImage objects, and not SwiftUI views directly. However, you can work around this by rendering the SwiftUI view to a UIImage first, and then using that image as a texture for your AR model.
Here’s how you can approach this:
Rendering SwiftUI view to UIImage: We use the UIHostingController to host the SwiftUI view inside a UIView and then render that view as an image using UIGraphicsImageRenderer. The rendered image can be used as a texture in ARKit.
Applying opacity and blur: The custom SwiftUI view, CustomBlurTranslucentView, has an image with blur and opacity effects applied. After rendering it as an image, we can adjust the opacity if needed before applying it as a texture.
Texture application in ARKit: Once the image is rendered and processed, we convert it to a TextureResource and assign it to the material of the ModelEntity, which is then placed on a plane mesh in ARKit.
Key Notes: UIImage Rendering: The image here is not directly from an ImageView, but from a UIView (UIHostingController wrapping a SwiftUI view). This means you have full flexibility to create complex views like the one with a blur and opacity effect before rendering it. Performance Consideration: Rendering images in this way for each frame can be computationally expensive. For complex views or frequent updates, you might want to cache the result or limit the updates. UnlitMaterial: This material is used to avoid any lighting effects and display the image as-is, which works well for UI elements like this.
@Prakash
I have changed the code to:
const express = require('express');
const app = express();
const bcrypt = require('bcrypt');
const jwt = require('jsonwebtoken');
const sqlite3 = require('sqlite3').verbose();
const path = require('path'); // Required for serving static files
const PORT = process.env.PORT || 3000;
const cors = require('cors');
app.use(cors({
origin: '*', // Allow both local and network access
methods: 'GET,POST,PUT,DELETE,OPTIONS',
allowedHeaders: 'Content-Type,Authorization',
credentials: true // Allow cookies if necessary
}));
app.options('*', cors());
// Middleware for parsing JSON
app.use(express.json());
// For serving static assets like images
app.use('/assets', express.static(path.join(__dirname, 'assets'), {
setHeaders: (res) => {
res.setHeader('Access-Control-Allow-Origin', '*');
}
}));
This allows me to access in Firefox, but not devices on my network.
This is not a solution but a few steps to try out.
It is worth experimenting with different partition configuration and page size. By default, thingsboard uses MONTHLY partitioning , you can change it to DAYS or other supported values and check.
The default_fetch_size parameter decides the size of a page while fetching data from Cassandra, the default value is 2000 records, you can try changing that and obeserve.
Also, if you can modify the source code, you can add a custom partitioning logic like weekly or bi-weekly.
Change Client Sercet (Post) to None in tab Credentials
when I tried it on my own computer, the step asking for credentials came up. I think your problem is network based. To understand this, you should telnet from your computer and check if that port is allowed to exit on your computer.
Step 1: Cmd > appwiz.cpl > turn windows features on or off > select and install telnet client
Step 2: Cmd > telnet trainingazure1.database.windows.net 1433 If the result returned is that the connection could not be opened, it means that the network you are on does not have access to sql from 1433. If you are sure that you are trying from behind a firewall, you should ask the system administrator to define a rule for 1433 and allow it.
You are trying from a company network, you can test this by trying from a place that is not restricted for testing.
For security reasons, ports other than standard ports (80,443,21,22,3389) may be closed, I suggest you make sure by trying.
If there is no solution, if you provide more information, we can try to understand the situation more.
Few questions:
👍🏼no se de q carajos trata responder pero hasta acá me trajo una alerta de mi teléfono
I usually use a flow like this when triggering things with Teams and Power Automate:
Trigger: "When keywords are mentioned" - This is needed to get "Message ID"
Action: "Get message details" - Here you use the "Message ID"
Action: "Compose" or "Initialize Variable" according your needs
To get the message content use this expression in your compose or variable: "outputs('Get_message_details')?['body/body/plainTextContent']"
Add the css using the lang
attribute so when you change the different language, the css is applied as per language.
[lang="en"] .navbarIcon {
margin-left: 60%;
}
[lang="en"] .localiza {
margin-left: 10%;
}
[lang="fr"] .navbarIcon {
margin-left: 60%;
}
[lang="fr"] .localiza {
margin-left: 10%;
}
You can find the lang code on your page when you inspect the element with your code in the HTML tag that shows the lang code.
const pathname = usePathname();
<Link href={`${pathname}/locations`}>Hello</Link>
You should use the pathname to get the current path and append it to the new URL, as Link will navigate to the new URL directly without retaining the previous path.
Using Next Js 14 version
Jim's comment gave me an idea, and I managed to find the root of the problem: MONGODB_URI
value should be quoted:
--env MONGODB_URI="$MONGODB_URI" \
I getting following message while trying to import transactions through xml
Line 120: Start and end tags are not same (null), (null).
You can find complete help here - Link
Are you sure it is breadth first search and not best first search as best first search is actually an greedy algorithm.
as per nextjs offical documentation
export const revalidate = 3600;
The value 3600 represents seconds, which equals 1 hour revalidate at most every hour
Future Reference: Packages can be updated/removed/reinstalled via the package manager in unity. I had an issue when updating a project to a newer version, and had an issue with a package not being found. I went to the package manager and removed the problem package which solved the issue.
Re-initialize the Gauge for the Maven Project.
Try to replace FlatList with Flashlist (https://github.com/Shopify/flash-list) and add some specific props like estimatedItemSize.
BPM provides the opportunity to integrate AI into an organizational system, enhancing workflow automation and decision-making through AI capabilities in data analysis, pattern recognition, and real-time decision making. The integration would look as follows:
Automating Repetitive Tasks: AI-powered BPM tools can automate routine tasks by using machine learning algorithms that continuously learn from process data. For example, AI can process customer inquiries, handle invoices, or monitor inventory levels automatically, freeing up human resources for more strategic work.
AI uses historical and real-time data analysis to predict outcome and trends; hence, using AI with BPM can help business organizations anticipate possible issues before their occurrence. Through the integration of AI with BPM, companies are able to take informed decisions, such as supply chain disruptions and customer demand fluctuation.
Optimizing Workflow Efficiency: An AI can spot most of the bottlenecks that are usually overlooked by human beings. BPM systems can now be optimized in real time through continuous assessment of process flows using AI. Thus, operations can now be smoother and faster response times result.
Intelligent Process Automation: AI-based BPM platforms take BPM way beyond simple automation and add decision-making capabilities. AI models can analyze intricate scenarios and make decisions that would otherwise demand human judgment. These include approvals of transactions, routing of customer service tickets, or adjusting supply chain parameters as situations change.
Continuous Improvement: BPMs integrated with AI can learn from past data and continuously improve processes. By using machine learning, businesses evolve processes to adjust to new challenges and opportunities and become more agile in their operations.
Conclusion: Introducing BPM into AI can make business processes more automated, improve decision-making in real-time, and help organizations be more dynamic in response to complex environments to achieve efficiency and competitiveness.
open terminal hit this command "defaults write com.apple.iphonesimulator ShowSingleTouches 1" and than restart the simulator once.
I think on htmx it's through hx-validate="true"
i.e.
<form hx-post="/assessment-result.php" hx-validate="true">
<input type="text" required pattern="[a-zA-Z]+" />
<button type="submit">Submit</button>
</form>
you can check these repos the way they implement validation as well.
Hi you have to create your custom label and then you put the date picked inside the overlay and then you .colorMultiply(.clear) to hide the datePicker. Check this answer for more info https://stackoverflow.com/a/77426363/26672380
To run on Windows 7 you need to install and older version of Cygwin
The Cygwin Time Machine
website will allow you to do so
http://www.crouchingtigerhiddenfruitbat.org/cygwin/timemachine.html
Check the compatibility between the kie-ci version you're using and the versions of maven-aether-provider and maven-resolver. You might need to upgrade or downgrade one of these to ensure compatibility. Make sure you're not mixing incompatible versions. For example, if you're using kie-ci 8.44.0, check its documentation for compatible versions of maven-aether-provider and maven-resolver.
Also You can exclude specific versions causing issues..and include new one which is compatible.
I think what you're looking for is what can you do other than prop drilling
-- what you mentioned.
If you want to pass a prop let's say down 10 children, a good idea would be to pass the prop onto a global state like context, redux, zustand, etc. So that you can access the state / data/ etc anywhere without drilling down.
Module not found: Error: Can't resolve './App'
I had facing the same issue, after a long research, what I realized myself is that, u gotta include suffix of ur file, I fixed my issue just adding .tsx behind './App'
Instance: Code having error: import App from './App'; Compilation Fixed: import App from './App.tsx';
Try it out if this fix ur issue!
When comparing Laravel vs Symfony, especially in the context of handling model attributes, it’s essential to understand how both frameworks manage and interact with models.
Laravel:
Laravel uses Eloquent ORM, which provides an intuitive, Active Record-style approach for working with database records. Model attributes in Laravel are defined as columns in the database, and you can manipulate them directly as properties of the model object.
Symfony:
Symfony relies on Doctrine ORM, which follows the Data Mapper pattern. In Symfony, model attributes are represented as class properties and require explicit definitions using annotations or XML/YAML mapping.
Symfony’s approach offers more control and is well-suited for projects that require strict separation of concerns.
Key Differences:
Ease of Use: Laravel's Eloquent is simpler to learn and use, making it great for quick development.
Flexibility: Symfony with Doctrine provides more robust mapping and advanced database features, ideal for complex applications.
Community & Ecosystem: Laravel has a vibrant ecosystem and packages, while Symfony is favored for enterprise-grade solutions.
Both frameworks are powerful, but your choice depends on project requirements and developer familiarity. For instance, if rapid development and ease of use are priorities, Laravel might be the better choice. On the other hand, if your application demands scalability and complex data models, Symfony excels.
Let me know if you’d like a deeper dive into Laravel vs Symfony comparisons or specific use cases!
So Solved it like this.
As mentioned that with the upgrade of Spring boot 2.x to 3.0.X it failed. So we needed to use the classic JarLauncher the new package wasnt working. So upped the jar version to 3.3.X and with it added a mavern setting to use CLASSIC jarLauncher.
https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-3.2.0-RC1-Release-Notes
That made the springboot app to startup. but on the Spring-Ui page there was no operation listed saying "No operation found in spec!"
For that we tried multiple things with springboot 3.3.0 to 3.3.4 but didnt work. When upped the version to 3.3.5 it started to work.
Hopefully this helps some one.
You can rotatate the labels in x-axis to fix the overlapping.
ax=plt.gca()
for item in ax.xaxis.get_ticklabels():
item.set_rotation(+45)
They are geniuses. I was able to solve the problem with the answer:
NOT ( EXISTS( Select analyzed.UnitID FROM analyzed WHERE [NotHeard].UnitID = analyzed.UnitID) AND EXISTS( Select analyzed2.UnitID FROM analyzed2 WHERE [NotHeard].UnitID = analyzed2.UnitID) )
It seems there was an issue with the npm installation command. Let's break down the problem and provide a solution.
Here's what we can do to resolve this issue:
package.json
file is located.npm install multer-storage-cloudinary
npm cache clean --force
npm install multer-storage-cloudinary
package.json
file to ensure there are no conflicts or issues with existing dependencies.yarn add multer-storage-cloudinary
node --version
Make sure you're using a version that's compatible with the package you're trying to install.
If you're still encountering issues after trying these steps, please provide the contents of your package.json
file and the full error log. This will help in diagnosing the problem more accurately.
I hace this video, about vercel and Nest js with GQL
The website was taking cache and when opened on incognito tab it was running.
So a solution that worked for me was placing glfw source directory in my project as a subdirectory.
However, I don't know if that's the best thing to do. In this scenario, is there a different way I can reference this subdirectory without having to place the entire folder on my local machine's file structure?